warning for unsigned fixed width shift left is twice #3289
Labels
enhancement
This topic discusses an improvement to existing compiler code.
fixed
This topic is considered to be fixed.
Take:
p4c produces:
If we change 6 to 5, the first warning is gone but maybe it should not be; I think there is an off by one error.
The second warning is another interesting one as I thought shifts have a well defined behavior always. How can there be a mismatch?
Also the specification only talks about overflow for the signed case and no overflow for the unsigned case so both of these warnings should not be there.
The text was updated successfully, but these errors were encountered: