]> git.lizzy.rs Git - rust.git/commit
Provide a sound method of flushing stdout
authorAlex Crichton <alex@alexcrichton.com>
Fri, 1 Nov 2013 05:09:48 +0000 (22:09 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Fri, 1 Nov 2013 05:09:48 +0000 (22:09 -0700)
commit8f258ab532eebce705b5eb27cc8635400992ca54
treed7f5f7ff4dae3c01f40fb337f103946cc7cc28af
parentd04a58cf2d224f6e0ae69334f90a9013ae2ba35a
Provide a sound method of flushing stdout

The previous method was unsound because you could very easily create two mutable
pointers which alias the same location (not sound behavior). This hides the
function which does so and then exports an explicit flush() function (with
documentation about how it works).
src/libstd/rt/io/stdio.rs