aboutsummaryrefslogtreecommitdiff
path: root/examples/v.ct
diff options
context:
space:
mode:
Diffstat (limited to 'examples/v.ct')
-rw-r--r--examples/v.ct12
1 files changed, 12 insertions, 0 deletions
diff --git a/examples/v.ct b/examples/v.ct
new file mode 100644
index 0000000..2026d55
--- /dev/null
+++ b/examples/v.ct
@@ -0,0 +1,12 @@
+main(argc u32, argv[argc] *u8) i32
+{
+ ctx(vec(u32) a);
+ // equivalent to
+ ctx(struct (vec[u32]) a);
+
+ // All entities defined with struct [vector<u32>] are seen as the same
+ // structure, i.e. mangled the same. Something like vector_u32
+ // If someone adds a name, i.e. structure lol [vector(u32)] the mangling
+ // is lol_vector_u32 and considered a different type. All identical
+ // definitions of structs are considered the same struct, in short.
+}