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

Enforce laziness of deferred libraries in dev_compiler #27776

Closed
munificent opened this issue Nov 7, 2016 · 1 comment
Closed

Enforce laziness of deferred libraries in dev_compiler #27776

munificent opened this issue Nov 7, 2016 · 1 comment
Labels
area-web Use area-web for Dart web related issues, including the DDC and dart2js compilers and JS interop. web-dev-compiler

Comments

@munificent
Copy link
Member

As of 8daf4cf, dev_compiler now supports the loadLibrary() function on deferred libraries. However, it does not validate that you call that before the library is used. This currently runs:

import "something.dart" deferred as something;

main() {
  // No loadLibrary() call.
  something.someFunction();
}

It would be great if dev_compiler threw an error here. Otherwise, users can iterate on programs that work fine in dev_compiler but fail when a production build is run.

@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
@Markzipan
Copy link
Contributor

This should be fixed as of https://dart-review.googlesource.com/c/sdk/+/177620!

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. web-dev-compiler
Projects
None yet
Development

No branches or pull requests

3 participants