Is it possible to disable C++ "Semantic Issue" warnings when working on a C project?
-
I'm in a CompSci 1 class and we're using C. Consequently, I get a lot of warnings about things that are depreciated or bad practice in C++, but perfectly legal in C and it's pretty annoying. I'm compiling .c files with clang and I don't get any compiler warnings—I'm referring only to the little yellow warning symbols next to the line numbers:
Is it possible to turn these off?
-
I'm in a CompSci 1 class and we're using C. Consequently, I get a lot of warnings about things that are depreciated or bad practice in C++, but perfectly legal in C and it's pretty annoying. I'm compiling .c files with clang and I don't get any compiler warnings—I'm referring only to the little yellow warning symbols next to the line numbers:
Is it possible to turn these off?
Hi,
I don't get those with QtCreator 4.1 with the old code parsing. Are you by any chance using the clang code model? If so you should try tweaking the configuration. Look up Tools > Options > C++ > Code model
Kind regards.
-
Thank you. Adding a custom entry with "-std=c99 -Weverything" does exactly what I wanted.
For any future readers, the complete set of options is here.
-
@kshegunov said in Is it possible to disable C++ "Semantic Issue" warnings when working on a C project?:
Look up Tools > Options > C++ > Code model