The way I look at it, read is a very generic function whose semantics support a
wide array of use cases. Using partially_initialized_array reflects the full
generality of those semantics. Surely no one would dispute that if I want the
behavior of any old bytes remaining initialized, that behavior is indeed
guaranteed by the standard and all implementations?
One particular possible use case that comes to mind: Perhaps I store some
default value in my buffer, and then allow it to be overridden by something I
read from a file descriptor. Then if read returns 0 or -1, my buffer is still
ready to go to use however I wanted.
~Shea
> --
> You received this message because you are subscribed to the Google Groups "ats-lang-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
ats-lang-user...@googlegroups.com.
> To post to this group, send email to
ats-lan...@googlegroups.com.
> Visit this group at
http://groups.google.com/group/ats-lang-users.
> To view this discussion on the web visit
https://groups.google.com/d/msgid/ats-lang-users/edd706ea-8cba-4b64-88d8-c39b23f41e83%40googlegroups.com.