I wonder if you have some opinions about changing the default message format for warnings. I think it should use --template=gcc by default. We can add a --template=cppcheck option to get the current output.
The biggest question imho is how this will affect the plugins and scripts.
If there is a script/plugin that need to parse the output then I think --xml should be used. The default textual output is not well suited for that.
If there is a script that runs cppcheck and just output the warnings then it will behave differently. But I think it will be better.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Actually, I always set --template=gcc so having it be default would be nice. Although, it doesnt work well when using the -j flag as shown in this issue:
I went ahead and changed the format now. I agree that ticket should be fixed. I also see some new problems with samples/memleak - the issue is not detected and it seems very strange if that somehow is caused by the changed template.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I wonder if you have some opinions about changing the default message format for warnings. I think it should use --template=gcc by default. We can add a --template=cppcheck option to get the current output.
The biggest question imho is how this will affect the plugins and scripts.
If there is a script/plugin that need to parse the output then I think --xml should be used. The default textual output is not well suited for that.
If there is a script that runs cppcheck and just output the warnings then it will behave differently. But I think it will be better.
Actually, I always set
--template=gcc
so having it be default would be nice. Although, it doesnt work well when using the-j
flag as shown in this issue:https://trac.cppcheck.net/ticket/9260
It seems like this issue should be fixed before we make it the default.
Last edit: Paul Fultz 2019-08-18
I went ahead and changed the format now. I agree that ticket should be fixed. I also see some new problems with samples/memleak - the issue is not detected and it seems very strange if that somehow is caused by the changed template.