aboutsummaryrefslogtreecommitdiff
path: root/examples/mutable.sloth
diff options
context:
space:
mode:
authorNic Gaffney <gaffney_nic@protonmail.com>2023-09-06 11:49:46 -0500
committerNic Gaffney <gaffney_nic@protonmail.com>2023-09-06 11:49:46 -0500
commit5711de4f146b543e08bb154c69d5b495a9dcd692 (patch)
tree0a21504d014429293370d308edf0b16b28ecfd6f /examples/mutable.sloth
parent7275a607d45d7e4f206f005584eef9ea5e331044 (diff)
downloadsloth-5711de4f146b543e08bb154c69d5b495a9dcd692.tar.gz
Immutables
Diffstat (limited to 'examples/mutable.sloth')
-rw-r--r--examples/mutable.sloth7
1 files changed, 7 insertions, 0 deletions
diff --git a/examples/mutable.sloth b/examples/mutable.sloth
new file mode 100644
index 0000000..7ea6a96
--- /dev/null
+++ b/examples/mutable.sloth
@@ -0,0 +1,7 @@
+fn main() {
+ val test = 0;
+ println(istr(test));
+ #test = 1;
+ println(istr(test));
+ return 0;
+}