Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(594)

Unified Diff: lib/src/checker/resolver.dart

Issue 1170813008: fixes detection of SDK libraries (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: format Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: lib/src/checker/resolver.dart
diff --git a/lib/src/checker/resolver.dart b/lib/src/checker/resolver.dart
index 5032888b3174a500014cbf4cde95d84445c2bef4..bd080e970ba0fea76194e9e139a008b9a3834bfb 100644
--- a/lib/src/checker/resolver.dart
+++ b/lib/src/checker/resolver.dart
@@ -595,9 +595,7 @@ class RestrictedStaticTypeAnalyzer extends StaticTypeAnalyzer {
}
var e = node.methodName.staticElement;
- if (e is FunctionElement &&
- e.library.name == '_foreign_helper' &&
- e.name == 'JS') {
+ if (isInlineJS(e)) {
// Fix types for JS builtin calls.
//
// This code was taken from analyzer. It's not super sophisticated:

Powered by Google App Engine
This is Rietveld 408576698