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

VariableElement.computeType does not use the right scope. #15700

Closed
johnniwinther opened this issue Dec 18, 2013 · 2 comments
Closed

VariableElement.computeType does not use the right scope. #15700

johnniwinther opened this issue Dec 18, 2013 · 2 comments
Labels
area-web Use area-web for Dart web related issues, including the DDC and dart2js compilers and JS interop. type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js

Comments

@johnniwinther
Copy link
Member

VariableElement.computeType does not use the right scope since local declaration are not taken into accounter. For instance:

class Foo {}

void test(var o) {
  String Foo;
  void m(Foo foo) {}
}

Here the type of 'foo' will be the class 'Foo' and not the malformed type that is the reference of the local variable 'Foo'.


Attachment:
compute_type.dart (159 Bytes)

@kevmoo kevmoo added type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) and removed priority-unassigned labels Feb 29, 2016
@vsmenon vsmenon added the area-web Use area-web for Dart web related issues, including the DDC and dart2js compilers and JS interop. label Jul 20, 2019
@srawlins
Copy link
Member

srawlins commented Aug 9, 2019

Obsolete as of CFE?

@johnniwinther
Copy link
Member Author

Yes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-web Use area-web for Dart web related issues, including the DDC and dart2js compilers and JS interop. type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js
Projects
None yet
Development

No branches or pull requests

4 participants