cpp/io/manip/ws

Discards leading whitespace from an input stream.

Behaves as an, except that is not modified. After constructing and checking the sentry object, extracts characters from the stream and discards them until any one of the following conditions occurs:


 * end of file condition occurs in the input sequence (in which case the function calls but does not set ; this does not apply if the  is already set on  prior to the call to, in which case the construction of the sentry object would set ).


 * the next available character in the input sequence is not whitespace as determined by . The non-whitespace character is not extracted.

This is an input-only I/O manipulator, it may be called with an expression such as for any  of type std.

Return value
(reference to the stream after extraction of consecutive whitespace)