Commit 9c898780 authored by Matthew Fernandez's avatar Matthew Fernandez
Browse files

fix: suppress -Wconstant-conversion warning

When Rumur infers a narrow signed type (e.g. int8_t) can be used to represent
scalars, the initialisation sequence used in for loops resulted in implicit
promotion to int and then implicit conversion back to the value type. This is
all intentional and not incorrect, but it appeared to the compiler as if the
generated code did not intend this final implicit conversion. By introducing
some casts, we squash this compiler warning.

The upcoming for-step-neg-overflow.m test case will demonstrate how to provoke
this situation.
parent a2a45efb
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment