Me*****@gmail.com wrote:
Zorro wrote:
In header file istream there is an overload for every built-in type,
except char. Is there a reason for this?
GCC 3.3.4. is the compiler.
Thanks.
For char and others there's a global operator>>, not member of
istream..
See [27.6.1.2.3] character extraction templates.
Thanks Mehturt. I read that. However, I could not see a technical
reason. So the question is this. Is it a decision, or there is a sound
technical reason for specializing the operator for bool (which is a
char) but not for types of char and "unsigned char"? For instance, if I
do it myself in the header file, will something go wrong at run time? I
am not saying that I will actually change the system header file.
Thanks.