coding guidelines: comply with MISRA Rule 13.4

- avoid to use assignment expression value

Signed-off-by: Hess Nathan <nhess@baumer.com>
This commit is contained in:
Hess Nathan 2024-05-02 14:16:58 +02:00 committed by Anas Nashif
parent 680fa154bf
commit fe06ffb37f
2 changed files with 2 additions and 2 deletions

View File

@ -1060,7 +1060,7 @@ static char *encode_float(double value,
/* Fraction is subnormal. Normalize it and correct
* the exponent.
*/
while (((fract <<= 1) & BIT_63) == 0) {
for (fract <<= 1; (fract & BIT_63) == 0; fract <<= 1) {
expo--;
}
}

View File

@ -537,7 +537,7 @@ static inline struct rbnode *stack_left_limb(struct rbnode *n,
f->stack[f->top] = n;
f->is_left[f->top] = 0U;
while ((n = get_child(n, 0U)) != NULL) {
for (n = get_child(n, 0U); n != NULL; n = get_child(n, 0U)) {
f->top++;
f->stack[f->top] = n;
f->is_left[f->top] = 1;