Index: sdk/lib/_internal/compiler/implementation/ssa/codegen.dart |
diff --git a/sdk/lib/_internal/compiler/implementation/ssa/codegen.dart b/sdk/lib/_internal/compiler/implementation/ssa/codegen.dart |
index d51850f9278c5bdf8c0d734084f33b01ffe699b8..69805d3d70ff79e7fe9bb9aaf4fa13706e0d38da 100644 |
--- a/sdk/lib/_internal/compiler/implementation/ssa/codegen.dart |
+++ b/sdk/lib/_internal/compiler/implementation/ssa/codegen.dart |
@@ -1729,7 +1729,9 @@ abstract class SsaCodeGenerator implements HVisitor, HBlockInformationVisitor { |
// property should not be mangled. |
push(new js.PropertyAccess.field(pop(), 'length'), node); |
} else { |
- String name = backend.namer.getName(node.element); |
+ String name = node.element.isNative() |
+ ? node.element.nativeName() |
+ : backend.namer.getName(node.element); |
push(new js.PropertyAccess.field(pop(), name), node); |
HType receiverHType = types[node.receiver]; |
DartType type = receiverHType.computeType(compiler); |
@@ -1741,7 +1743,9 @@ abstract class SsaCodeGenerator implements HVisitor, HBlockInformationVisitor { |
} |
visitFieldSet(HFieldSet node) { |
- String name = backend.namer.getName(node.element); |
+ String name = node.element.isNative() |
+ ? node.element.nativeName() |
+ : backend.namer.getName(node.element); |
DartType type = types[node.receiver].computeType(compiler); |
if (type != null) { |
// Field setters in the generative constructor body are handled in a |