summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorKai Stevenson <kai@kaistevenson.com>2023-02-18 23:27:30 -0800
committerKai Stevenson <kai@kaistevenson.com>2023-02-18 23:27:30 -0800
commit51659aa7b33baa490a614255996f3e372e86a67c (patch)
tree594fdd6abe4f28cff477d63af37933fdb90a6005 /examples
parente8df5cd395569ddd944900ec7f22236db491b5a8 (diff)
fixed eval() scoping
Diffstat (limited to 'examples')
-rw-r--r--examples/helloworld1.pcdt1
-rw-r--r--examples/helloworld2.pcdt2
-rw-r--r--examples/recursion.pcdt2
-rw-r--r--examples/scopetest.pcdt2
4 files changed, 2 insertions, 5 deletions
diff --git a/examples/helloworld1.pcdt b/examples/helloworld1.pcdt
deleted file mode 100644
index a52e207..0000000
--- a/examples/helloworld1.pcdt
+++ /dev/null
@@ -1 +0,0 @@
-store(hello world; hlVar;)
diff --git a/examples/helloworld2.pcdt b/examples/helloworld2.pcdt
deleted file mode 100644
index 084ce45..0000000
--- a/examples/helloworld2.pcdt
+++ /dev/null
@@ -1,2 +0,0 @@
-@helloworld1.pcdt
-store(print(hlVar()) HelloWorldFunc;)
diff --git a/examples/recursion.pcdt b/examples/recursion.pcdt
index 88b81f5..3f57a6e 100644
--- a/examples/recursion.pcdt
+++ b/examples/recursion.pcdt
@@ -1,2 +1,2 @@
-store( (print(arg0()) incFunc(sum(1; arg0())) ) incFunc;)
+store( ref((print(arg0()) incFunc(sum(1; arg0())))) incFunc;)
incFunc(0;)
diff --git a/examples/scopetest.pcdt b/examples/scopetest.pcdt
index 2aeb6ad..78418e2 100644
--- a/examples/scopetest.pcdt
+++ b/examples/scopetest.pcdt
@@ -1,2 +1,2 @@
-store(ref(print(hello;)) myFunc;)
+store(ref(ref(print(hello;))) myFunc;)
eval(myFunc())