79193105

Date: 2024-11-15 16:02:33
Score: 2.5
Natty:
Report link

Linux Mint 21.3 Cinnamon; Kernel: 5.15.0-125-generic

Resolved: Compiler path somehow changed to /.../clang++. Changed to /.../gcc and all is repaired.

How problem started: I Created a new text file and named it with *.cpp. Should not have been a problem but thats when my very similar problems started immediately afterwards. Maybe it somehow got changed inadvertently while creating it this way? I dont know how...

Followed most of steps above from @Damilare Oyediran which was very helpful:

Fyi, Linux uses GCC as the compiler as I understand- "GCC stands for GNU Compiler Collection. It is a set of compilers for various languages including C, C++, Objective-C, Fortran and more..."; cite link at bottom.

a. same b. same c. Mine stated usr/bin/cLang++. This turned out to be the incorrect path somehow selected as default. Mine worked after changing to /usr/bin/gcc d. My OS is Linux. To check version of GCC compiler from terminal: "gcc --version",,, or "gcc -v", the latter which gives more details, in particular the path: Mine is /usr/bin/gcc. e. VS Code IntelliSense Configurations UI drop down choices indeed displayed /usr/bin/gcc, option so I selected it. IntelliSense automatically updated the Visual Studio programs in progress real time which was open while doing this fix- all good now. It also automatically updated the c_cpp_properties.jason file in real time as well since it too was open while proceeding with the fix.

I bounced the above very helpful steps from @Damilare Oyediran, relative to Linux OS at the following link: https://thelinuxcode.com/check-the-version-my-gcc-compiler/.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Unregistered user (0.5):
  • User mentioned (1): @Damilare
  • User mentioned (0): @Damilare
  • Low reputation (1):
Posted by: js891ster