OneMoreGres / qtc-cppcheck

Qt Creator Cppcheck integration plugin [deprecated]
MIT License
126 stars 37 forks source link

Custom parameters not added to cppcheck command line #30

Closed gilprime closed 7 years ago

gilprime commented 7 years ago

When using qtccppcheck with default values (just setting the executable path), i've got many errors like this :

C:\blahblahpath\mysuperfile.h:11: erreur : Cppcheck(syntaxError): Code 'classMySuperFile:' is invalid C code. Use --std or --language to configure the language. C:\blahblahpath\myothersuperfile.h:15: erreur : Cppcheck(syntaxError): Code 'template<...' is invalid C code. Use --std or --language to configure the language.

So, i've added custom parameters to the cppcheck plugin interface : --std=c++11 --language=c++

But they are not taken in account when executing the cppcheck executable. Since i've checked the Show binary output i can now view the command line executed that is :

Starting CppChecker with:C:/Program Files/Cppcheck/cppcheck.exe, --enable=warning,style,performance,portability,information,missingInclude,unusedFunction --inconclusive --template={file},{line},{severity},{id},{message} --file-list=C:/Users/JohnDoe/AppData/Local/Temp/qtcreator.T10400 --includes-file=C:/Users/JohnDoe/AppData/Local/Temp/qtcreator.x10400

Currenly using Windows 7 x64 - QtCreator 4.3.0 - Qtccppcheck 4.3.0

OneMoreGres commented 7 years ago

Should be fixed. You can try 4.3.1 binaries from here.

gilprime commented 7 years ago

It's fixed, thanks :)