Index: pkg/compiler/lib/src/js_backend/constant_emitter.dart |
diff --git a/pkg/compiler/lib/src/js_backend/constant_emitter.dart b/pkg/compiler/lib/src/js_backend/constant_emitter.dart |
index f01f0d079e3ad55a3aae269686186f767e5a95dc..b113d2409c116face6a1c46e6fe3ec4f641d6111 100644 |
--- a/pkg/compiler/lib/src/js_backend/constant_emitter.dart |
+++ b/pkg/compiler/lib/src/js_backend/constant_emitter.dart |
@@ -270,7 +270,7 @@ class ConstantEmitter |
@override |
jsAst.Expression visitConstructed(ConstructedConstantValue constant, [_]) { |
Element element = constant.type.element; |
- if (element.isForeign(backend) |
+ if (backend.isForeign(element) |
&& element.name == 'JS_CONST') { |
StringConstantValue str = constant.fields.values.single; |
String value = str.primitiveValue.slowToString(); |