Skip to content

Fixed MISRA rule 12.7 for GX_FIXED_VAL_... macros - #171

Open
parsley wants to merge 1 commit into
eclipse-threadx:devfrom
parsley:fix_misra_rule_12.7
Open

Fixed MISRA rule 12.7 for GX_FIXED_VAL_... macros#171
parsley wants to merge 1 commit into
eclipse-threadx:devfrom
parsley:fix_misra_rule_12.7

Conversation

@parsley

@parsley parsley commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Fixed MISRA rule 12.7 violation on GX_FIXED_VAL_... macros by replacing shift operations on signed operands with mul/div operations.
On these lines also rule 19.10 got addressed.

Luckily this fix was relatively easy because GX_FIXED_VAL_SHIFT and GX_FIXED_VAL_ONE are both available and match.

I did not check all occurrences of GX_FIXED_VAL_SHIFT.
If this PR is not covering everything please feel free to change it, extend it or convert it in a feature request. 😉 I hope this helps.

…ng shift operations on signed operands with mul/div operations.

On these lines also rule 19.10 got addressed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant