2244. Issue on basic_istream::seekg

Section: [istream.unformatted] Status: C++17 Submitter: Juan Soulie Opened: 2013-03-04 Last modified: 2017-07-30 20:15:43 UTC

Priority: 3

View all other issues in [istream.unformatted].

View all issues with C++17 status.


When issue 1445 was resolved by adopting N3168, it exposed the need to modify both overloads of basic_istream::seekg (by inserting "the function clears eofbit," after "except that"), but the fix applied to the text apparently forgets the second overload at [istream.unformatted] p43.

[2013-10-17: Daniel provides concrete wording]

It seems that the tiny sentence "SIMILARLY for (seekg)." had been overlooked. I agree that the wording needs to be applied here as well.

[2015-05-06 Lenexa: Move to Ready]

MC: This was just missed when we added "the function first clears eofbit" to the other overload, Daniel agrees. Editing mistake.

Move to Ready, consensus.

Proposed resolution:

This wording is relative to N3691.

  1. Change [istream.unformatted] p43 as indicated:

    basic_istream<charT,traits>& seekg(off_type off, ios_base::seekdir dir);

    -43- Effects: Behaves as an unformatted input function (as described in, paragraph 1), except that the function first clears eofbit, it does not count the number of characters extracted, and does not affect the value returned by subsequent calls to gcount(). […]