summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--testdata/scad/misc/value-reassignment-tests2.scad9
1 files changed, 9 insertions, 0 deletions
diff --git a/testdata/scad/misc/value-reassignment-tests2.scad b/testdata/scad/misc/value-reassignment-tests2.scad
new file mode 100644
index 0000000..9d7cf50
--- /dev/null
+++ b/testdata/scad/misc/value-reassignment-tests2.scad
@@ -0,0 +1,9 @@
+// Test reassignment where another variable has used the previous
+// value before the reassignment. This could get messed up if order of
+// assignment evaluation changes
+
+myval = 2;
+i = myval;
+myval = 3;
+echo(myval, i); // Should output 3, 2
+
contact: Jan Huwald // Impressum