cppreference.com > C++ I/O > rdstate
rdstate
Syntax:
  iostate rdstate();

The rdstate() function returns the io stream state flags of the current stream.