Intellisense: command-line error: invalid macro definition
I am having problem regarding intellisense :
IntelliSense: command-line error: invalid macro definition: _CRT_SECURE_CPP_OVERLOAD_STANDARD_NAMES_COUNT =1 d:\Bharat\Max\CreateMatFile\createMatFile3\createMatFile3\createMatFile3.cpp
In my visual studio 2012 for c++ project. Anyone can help me out to resolve this would be highly appreciated.
I had the very same problem and I managed to remove the space before " =1" as follows:
- Go to the "Property Manager": in the menu select "View" -> "Property Manager"
- Navigate to your appropriate solution and platform (e.g. "Release | x64") and expand it to see the property sheets
- Now search these property sheets for the wrong preprocessor settings as follows:
- Right click on the property sheet and select "Properties"
- Go for the preprocessor settings: "Common Properties" -> "C/C++" -> "Preprocessor"
- Remove the missplaced space
In my configuration one of these property sheets had the wrong preprocessor setting with the additional space " =1". I fixed it and voilà intellisense worked again!
In case of error message
e0992 command-line error: invalid macro definition: _m_cee=001
problem was solved by:
- Right click on the target project in "Solution Explorer" and select "Properties"
- Go to section "Configuration Properties" -> "C/C++" -> "Command Line"
- In an Additional parameters add an option "/Zc:twoPhase-"
- Apply and rebuild the project.
Also will be helpful to see build log file $(IntDir)$(MSBuildProjectName).log (Name can be redefined in "General" -> "Build Log File" configuration section)
PS: In case of using C++/CLI