char_traits::eof

char_traits::eof

static int_type eof();

The static member function returns a value that represents end-of-file (such as EOF or WEOF). If the value is also representable as type E, it must correspond to no valid value of that type.