Talk:cpp/io/basic istream/ignore

Hello Cubbi,

Could you explain what issues are in my changes of the example, please? I want to improve myself and therefore would be really thankful, if you could tell me about that.

Sincerely

Sam Halvoe (talk)
 * there was a variable outside its scope, there was duplicated code ("cin >> n" two times), and the non-uniform handling of error states made the example harder to follow. What was the reason for changing the code in the first place? There was no discussion or even an edit comment. --Cubbi (talk) 19:02, 21 September 2017 (PDT)
 * I think it would be more readable, but your arguments make sense. Sorry, that I didn't mention my intention. Next time when I edit something, I will start a discussion first or at least I will comment my edit.


 * Sincerely


 * Sam Halvoe (talk) 00:06, 22 September 2017 (PDT)

Where's the history?
This function used to take -- in C++98 -- an int parameter instead of a streamsize parameter. Where are the nice "until C++11" and "since C++11" blocks?
 * it was always streamsize. In C++98, there was an editorial error where the declaration for this function (in 27.6.1.1) had streamsize, while the definition (in 27.6.1.3/23) had int. This was fixed by C++03. --Cubbi (talk) 23:10, 30 August 2018 (PDT)