cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
General C++ Programming
about cout << flush
about cout << flush
Dec 29, 2010 at 5:21am UTC
brxue
(1)
Hello,
Can anyone explain how does "cout << flush" is overloaded as "flush(cout)"?
What's the function prototype?
Thanks
Brian
Dec 29, 2010 at 11:05am UTC
Bazzy
(6281)
std::flush is a manipulator that calls std::ostream::flush
that is,
cout << flush;
is the same as
cout.flush();
flush makes sure that the buffer is cleared and the characters are written to their destination
http://www.cplusplus.com/reference/iostream/manipulators/flush/
http://www.cplusplus.com/reference/iostream/ostream/flush/
Topic archived. No new replies allowed.