https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92563
Martin Ettl <ettl.martin at gmx dot de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ettl.martin at gmx dot de --- Comment #3 from Martin Ettl <ettl.martin at gmx dot de> --- (In reply to Richard Biener from comment #2) > It's really an odd warning - the argument is passed by value, changing such > parameters never has an effect outside of the function. So is this really > asking to make by-value passing useless and asks for always putting 'const' > on such parameters? Yes it does, bit Cppcheck is configurable and it is possible to suppress this warning: Quoted from Cppcheck's manpage: --suppress=<spec> Suppress a specific warning. The format of <spec> is: [error id]:[filename]:[line]. The [filename] and [line] are optional. [error id] may be * to suppress all warnings (for a specified file or files). [filename] may contain the wildcard characters * or ?.