crashappsec / libcon4m

Base Compiler and Runtime Support for con4m
Apache License 2.0
0 stars 0 forks source link

assignops: /= behaves incorrectly with negative number #55

Closed ee7 closed 2 weeks ago

ee7 commented 2 weeks ago

With:

Example

x = 3
x /= -1
print(x)

Expected behavior

Outputs -3.

Observed behavior

Outputs 0.

viega commented 2 weeks ago

Yes, accidentally used the wrong type on the LHS when accessing the union; fixed in branch.