Reputation: 43
I have code which has lot of floating point arithmetic, for example:
float32_value1 += float32_value2
This results in MISRA QACPP level 3 warning - Expression(s) with floating point type used as operand(s) to +=
Is there any workaround to resolve this warning other than suppressing it?
Thanks in advance!
Upvotes: 0
Views: 691
Reputation: 21721
The MISRA rule in question is categorised as "Document". Rules in this category cannot be checked by analysis of the source code alone.
In this specific case the rule requires evidence that:
This information is not evident from the written source, however, adding a suppression with a reference to where that evidence exists is a possible approach to cover "Document" rules.
Upvotes: 1