F# Simple message reader using TCP
Why do you make this call Async.StartAsTask instead of just return the Async&lt;T&gt; to let the client handle that as needed?




  let rec StartReading (client:TcpClient) =


I would call it reader and then give it the signature of:

let rec reader frameNo (client:TcpClient) =


in order to get rid of reffor frameNumber.

You can then initially call it:

reader 0 client |&gt; Async.StartAsTask


and recursively:

return! reader (frameNo + 1) client