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

dart2js: type tests should not rely in undefined properties #9731

Open
rakudrama opened this issue Apr 7, 2013 · 5 comments
Open

dart2js: type tests should not rely in undefined properties #9731

rakudrama opened this issue Apr 7, 2013 · 5 comments
Assignees
Labels
area-web Use area-web for Dart web related issues, including the DDC and dart2js compilers and JS interop. P2 A bug or feature request we're likely to work on type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js

Comments

@rakudrama
Copy link
Member

rakudrama commented Apr 7, 2013

A dart2js program will be more robust if it does not rely on undefined properties.
A type test like !!x.$isT is relying on $isT not being defined on Object.prototype. This might not be the case with other components loaded into the page.

Once everything is a Dart object or an interceptor, default values for these flags can live on $.Object.prototype (the Dart Object).

@kasperl
Copy link

kasperl commented May 23, 2013

Added TriageForM5 label.

@kasperl
Copy link

kasperl commented May 28, 2013

Removed TriageForM5 label.

@kasperl
Copy link

kasperl commented Jul 10, 2014

Removed this from the Later milestone.
Added Oldschool-Milestone-Later label.

@kasperl
Copy link

kasperl commented Aug 4, 2014

Removed Oldschool-Milestone-Later label.

@rakudrama
Copy link
Member Author

Currently we always use getInterceptor (with standard optimizations) for these tests.
We still need default falsy values on Dart Object.

@kevmoo kevmoo added P2 A bug or feature request we're likely to work on type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) and removed triaged labels Feb 29, 2016
@rakudrama rakudrama changed the title dart2js: type tests should not reply in undefined properties dart2js: type tests should not rely in undefined properties Jan 5, 2018
@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
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. P2 A bug or feature request we're likely to work on type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js
Projects
None yet
Development

No branches or pull requests

6 participants