summaryrefslogtreecommitdiff
path: root/tests/test_method_2.tnsl
diff options
context:
space:
mode:
authorKyle Gunger <kgunger12@gmail.com>2024-03-12 01:18:46 -0400
committerKyle Gunger <kgunger12@gmail.com>2024-03-12 01:18:46 -0400
commitca9e965a7756b2a7f8de645f53b66dd96c4f279b (patch)
treeb4026b3422b0e20dc81fbf655357bb3510ad1203 /tests/test_method_2.tnsl
parent644a06a5b13b5a129528618050a9dff4f5281be8 (diff)
Better pointer handling
Diffstat (limited to 'tests/test_method_2.tnsl')
-rw-r--r--tests/test_method_2.tnsl17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/test_method_2.tnsl b/tests/test_method_2.tnsl
new file mode 100644
index 0000000..899cdcb
--- /dev/null
+++ b/tests/test_method_2.tnsl
@@ -0,0 +1,17 @@
+struct Vector {
+ ~void data,
+ int count, size, _elsz
+}
+
+/; method Vector
+
+ /; init (int elsz)
+ self._elsz = elsz
+ ;/
+;/
+
+/; main [int]
+ Vector a
+ a.init(1)
+ return a._elsz
+;/