About nullptr undefined in vscode

problem occurs

When writing C++ in vscode, I saw an error

report an error

The C++ keyword shows that it is not defined. If you think about it carefully, you will know that this is definitely impossible.
Try to compile it and there is no problem, indicating that there is a problem with vscode

Solve the problem

Open the user settings file of vscode File-
>Preferences->Settings

Enter the following settings inside the curly brackets in the right column

"args": ["-g","-Wall","-std=c++11","${file}","-o","${file}.exe"],

problem solved

Jiang ~ problem solved

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324989149&siteId=291194637