summary refs log tree commit diff stats
path: root/tests/js/tmangle.nim
diff options
context:
space:
mode:
Diffstat (limited to 'tests/js/tmangle.nim')
-rw-r--r--tests/js/tmangle.nim8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/js/tmangle.nim b/tests/js/tmangle.nim
index c4167ba39..c97bf7029 100644
--- a/tests/js/tmangle.nim
+++ b/tests/js/tmangle.nim
@@ -27,10 +27,10 @@ block:
   var global = T(a: 11, b: "foo")
   proc test(): bool =
     var obj = T(a: 11, b: "foo")
-    {. emit: [result, " = (", obj.addr[], "[0].a == 11);"] .}
-    {. emit: [result, " = ", result, " && (", obj.addr[], "[0].b == \"foo\");"] .}
-    {. emit: [result, " = ", result, " && (", global, "[0].a == 11);"] .}
-    {. emit: [result, " = ", result, " && (", global, "[0].b == \"foo\");"] .}
+    {. emit: [result, " = (", obj.addr[], ".a == 11);"] .}
+    {. emit: [result, " = ", result, " && (", obj.addr[], ".b == \"foo\");"] .}
+    {. emit: [result, " = ", result, " && (", global, ".a == 11);"] .}
+    {. emit: [result, " = ", result, " && (", global, ".b == \"foo\");"] .}
   echo test()
 
 # Test addr of field: