Add extract char operator to istream
This commit is contained in:
parent
e2f822e7d1
commit
148c288942
|
@ -952,6 +952,13 @@ istream & istream::operator>>(float & val)
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
istream & istream::operator>>(char & val)
|
||||||
|
{
|
||||||
|
doskipws();
|
||||||
|
val = get();
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
istream & istream::operator>>(char * p)
|
istream & istream::operator>>(char * p)
|
||||||
{
|
{
|
||||||
doskipws();
|
doskipws();
|
||||||
|
|
|
@ -124,6 +124,7 @@ public:
|
||||||
istream & putback(char c);
|
istream & putback(char c);
|
||||||
istream & unget(void);
|
istream & unget(void);
|
||||||
|
|
||||||
|
istream & operator>>(char & val);
|
||||||
istream & operator>>(bool & val);
|
istream & operator>>(bool & val);
|
||||||
istream & operator>>(int & val);
|
istream & operator>>(int & val);
|
||||||
istream & operator>>(unsigned & val);
|
istream & operator>>(unsigned & val);
|
||||||
|
|
Loading…
Reference in New Issue