I swear to God that I didn't do anything except the usual compiling and running c++ files. All of a sudden my code is refusing to compile both in VScode and gVim, here is the code and the error message
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
int main()
{
cout << "Hello world\n";
}
and the error message while compiling in both VScode and gVim .
C:\WINDOWS\system32\cmd.exe /c (g++ -std=c++14 cses.cpp -o cses -Wl,--stack,268435456)
In file included from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\sstream:813:0,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\complex:45,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\ccomplex:39,
from c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\mingw32\bits\stdc++.h:52,
from cses.cpp:1:
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\sstream.tcc:45:38: error: '_alloc' was not declared in this scope
basic_stringbuf<_CharT, _Traits, _alloc>::
^~~~~~
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\sstream.tcc:45:44: error: template argument 3 is invalid
basic_stringbuf<_CharT, _Traits, _alloc>::
^
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\sstream.tcc:46:15: error: 'int_type' was not declared in this scope
pbackfail(int_type __c)
^~~~~~~~
c:\mingw\lib\gcc\mingw32\6.3.0\include\c++\bits\sstream.tcc:47:5: error: expected ';' before '{' token
{
^
shell returned 1
What has happened? is my gcc corrupt or what because the code works fine in online compilers?This is actually happening for all C++ files I just noticed