Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CompilerVisitor.constants map cannot contain both 0 and 0.0. #16

Closed
eriksoe opened this issue Mar 2, 2010 · 1 comment
Closed

CompilerVisitor.constants map cannot contain both 0 and 0.0. #16

eriksoe opened this issue Mar 2, 2010 · 1 comment

Comments

@eriksoe
Copy link
Contributor

eriksoe commented Mar 2, 2010

CompilerVisitor.push_immediate() generates bad code for io_lib_format:fwrite_g/1; the code contains a reference to field "num_0" of type EDouble. The field exists, but has type ESmall.
This bug is caused by collision between ESmall(0) and EDouble(0.0) in the constants map maintained by push_immediate().

@krestenkrab
Copy link
Contributor

I fixed =:= to not compare 0 and 0.0 equals; and also added an equals method to EDouble. That seemed to do the trick for now.

This issue was closed.
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

No branches or pull requests

2 participants