cout implementation

C

candy_init

hi all,

Is it true that the cout function used in C++ for printing data
to the console is implemented via the "write" system call?
If not then how the cout function is implemented?

Thanks,
Candice
 
R

Rolf Magnus

Is it true that the cout function used in C++ for printing data
to the console is implemented via the "write" system call?

Maybe, or maybe not. That depens on the compiler/OS/library/...
Some OSs don't even have a "write" system call.
If not then how the cout function is implemented?

The C++ standard doesn't define that. It's up to the implemenation to decide
where the output of cout goes.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,184
Messages
2,570,978
Members
47,578
Latest member
LC_06

Latest Threads

Top