The various unformatted input functions all begin by constructing an object of type basic_istream::sentry and ends by destroying the sentry object.