At least some older implementations don't have
std::ios_base, so you should use
std::ios::badbit, std::ios::failbit
and std::ios::eofbit and
std::ios::goodbit.
