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

Unified Diff: pkg/compiler/lib/src/js_backend/backend.dart

Issue 2608273002: Reduce use of Element in optimize.dart (Closed)
Patch Set: Fix. Created 3 years, 11 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: pkg/compiler/lib/src/js_backend/backend.dart
diff --git a/pkg/compiler/lib/src/js_backend/backend.dart b/pkg/compiler/lib/src/js_backend/backend.dart
index 004dd0217e3b5520191ea7535bf0d4f0f9fa59f5..e0cc2538821e599128969aafb10c9f75e528386a 100644
--- a/pkg/compiler/lib/src/js_backend/backend.dart
+++ b/pkg/compiler/lib/src/js_backend/backend.dart
@@ -793,7 +793,7 @@ class JavaScriptBackend extends Backend {
bool isNative(Entity element) => nativeData.isNative(element);
/// Returns the [NativeBehavior] for calling the native [method].
- native.NativeBehavior getNativeMethodBehavior(FunctionElement method) {
+ native.NativeBehavior getNativeMethodBehavior(MethodElement method) {
return nativeData.getNativeMethodBehavior(method);
}
@@ -3271,7 +3271,12 @@ class JavaScriptBackendClasses implements BackendClasses {
}
@override
- bool isNative(Element element) {
+ bool isNativeClass(ClassElement element) {
+ return helpers.backend.isNative(element);
+ }
+
+ @override
+ bool isNativeMember(MemberElement element) {
return helpers.backend.isNative(element);
}
}

Powered by Google App Engine
This is Rietveld 408576698