std.Stream.InputStream convenience functions

bitwise via Digitalmars-d digitalmars-d at puremagic.com
Thu Sep 3 17:06:06 PDT 2015


On Friday, 4 September 2015 at 00:05:06 UTC, bitwise wrote:
> Thoughts?
> [...]

void main(string[] args)
{
     MemoryStream s = new MemoryStream();
     s.write(1);
     s.write(2);
     s.write(3);
     s.seek(0, SeekPos.Set);
     writeln(s.readInt());
     writeln(s.readInt());
     writeln(s.readInt());
}





More information about the Digitalmars-d mailing list