Closed dbanet closed 8 years ago
Expected behavior:
# uname Linux # cat <<EOF | g++ -std=c++11 -x c++ - > #include <string> > #include <iostream> > using namespace std; > main(){ string s="42"; > cout<<stol(s)<<endl; } > EOF # ./a.out 42
Present behavior:
# uname OS/2 # cat <<EOF | g++ -std=c++11 -x c++ - > #include <string> > #include <iostream> > using namespace std; > main(){ string s="42"; > cout<<stol(s)<<endl; } > EOF <stdin>: In function 'int main()': <stdin>:5:13: error: 'stol' was not declared in this scope
Workaround: g++ -std=gnu++11 -x c++ -D_GLIBCXX_USE_C99
g++ -std=gnu++11 -x c++ -D_GLIBCXX_USE_C99
I've fixed this problem in #23.
Fixed by commit fef1630c35955e6352f9734b43d20758ce7508be.
Expected behavior:
Present behavior: