I am using 2.3 and --std==c++20. I just added some code using operator<=> for the first time, and cppcheck complains about it. It does compile and run correctly under GCC 10.2, however.
This operator is not handled yet by cppcheck.. well if you would be interested to help us add handling for it let me know. I think adding it to the ast should be relatively easy. then it needs proper ValueType and some handling in the ValueFlow..
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I use cppcheck a lot, but have never looked at its source code. I think it would take me a very long time to contribute such an enhancement. I would not mind paying a small bounty if someone could do it.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
hmm.. I think there are these tasks:
* update preprocessor/tokenizer so it outputs a single token : ~30 minutes
* AST : ~30 minutes
* ValueType : 10 minutes
* ValueFlow: 1 hour
Then probably we want to tweak some code here and there, for instance isOppositeExpression.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am using 2.3 and --std==c++20. I just added some code using operator<=> for the first time, and cppcheck complains about it. It does compile and run correctly under GCC 10.2, however.
Here is the cppcheck output for that code:
Compare.C:16:35: error: syntax error: <= > [syntaxError]
if ( auto comp = ( leg1->Date() <=> leg2->Date() ); comp != 0 )
Is there an option that will allow cppcheck to support this yet?
This operator is not handled yet by cppcheck.. well if you would be interested to help us add handling for it let me know. I think adding it to the ast should be relatively easy. then it needs proper ValueType and some handling in the ValueFlow..
I use cppcheck a lot, but have never looked at its source code. I think it would take me a very long time to contribute such an enhancement. I would not mind paying a small bounty if someone could do it.
hmm.. I think there are these tasks:
* update preprocessor/tokenizer so it outputs a single token : ~30 minutes
* AST : ~30 minutes
* ValueType : 10 minutes
* ValueFlow: 1 hour
Then probably we want to tweak some code here and there, for instance isOppositeExpression.