27 Input/output library [input.output]

27.7 Formatting and manipulators [iostream.format]

27.7.2 Input streams [input.streams]

27.7.2.2 Formatted input functions [istream.formatted]

27.7.2.2.1 Common requirements [istream.formatted.reqmts]

Each formatted input function begins execution by constructing an object of class sentry with the noskipws (second) argument false. If the sentry object returns true, when converted to a value of type bool, the function endeavors to obtain the requested input. If an exception is thrown during input then ios::badbit is turned on314 in *this's error state. If (exceptions()&badbit) != 0 then the exception is rethrown. In any case, the formatted input function destroys the sentry object. If no exception has been thrown, it returns *this.

This is done without causing an ios::failure to be thrown.