Need help.

May 27, 2013 at 10:50pm
I recently switched compilers to a more up to date one (Orwell Dev-C++), and the following code no longer works, can you please help give me the code that works like the following

code
cin.ignore(numeric_limits<streamsize>::max(), '\n')
assuming your using the namespace
Last edited on May 27, 2013 at 10:51pm
May 27, 2013 at 11:17pm
Why does not the code work? Could you be more precise?
May 28, 2013 at 1:52am
[Error] 'numeric_limits' was not declared in this scope
[Error] expected primary-expression before '>' token
[Error] no matching function for call to 'max()'

c:\program files\dev-cpp\mingw64\lib\gcc\x86_64-w64-mingw32\4.7.1\include\c++\bits\char_traits.h In file included from c:\program files\dev-cpp\mingw64\bin\../lib/gcc/x86_64-w64-mingw32/4.7.1/include/c++/bits/char_traits.h
Last edited on May 28, 2013 at 1:54am
May 28, 2013 at 4:37am
#include <limits>
Topic archived. No new replies allowed.