Skip to content

[VM] Equality/inequality operators do not produce a constant expression if both arguments do not have the same type #1671

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

Closed
DartBot opened this issue Feb 14, 2012 · 5 comments
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.

Comments

@DartBot
Copy link

DartBot commented Feb 14, 2012

This issue was originally filed by [email protected]


Spec ch. 10.1:
An expression of one of the forms e1 == e2, e1 != e2, e1 === e2 or
e1! == e2 ,where e1 and e2 are constant expressions that evaluate to a
numeric, string or boolean value.

Doesn't say both expressions have to be the same type, but the following tests fail on VM:

initializer must be a compile time constant
final x3 = true != 1;
           ^
initializer must be a compile time constant
final x4 = "a" === false;
           ^

@anders-sandholm
Copy link
Contributor

Added Area-VM, Triaged labels.

@ghost
Copy link

ghost commented Feb 16, 2012

Set owner to @mhausner.

@iposva-google
Copy link
Contributor

Added Accepted label.

@floitschG
Copy link
Contributor

Issue #1794 has been merged into this issue.

@DartBot
Copy link
Author

DartBot commented Mar 30, 2012

This comment was originally written by @mhausner


Fixed at 6059.


Added Fixed label.

@DartBot DartBot added Type-Defect area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. labels Mar 30, 2012
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.
Projects
None yet
Development

No branches or pull requests

4 participants