summaryrefslogtreecommitdiff
path: root/docs/type_system/empty.md
diff options
context:
space:
mode:
authornodist <kevin.comas.git@gmail.com>2026-06-03 15:26:26 -0400
committernodist <kevin.comas.git@gmail.com>2026-06-03 15:26:26 -0400
commitf3e3fd0cdba8d2f9f49be279ac3c0ec87a44609b (patch)
treea993e1539cf90362141db8a4c43f1f9f3ff7ef42 /docs/type_system/empty.md
parentb26ad08b39b8229dcea0bafc4a8ba4b0d7ad7154 (diff)
refs with more impl
Diffstat (limited to 'docs/type_system/empty.md')
-rw-r--r--docs/type_system/empty.md16
1 files changed, 16 insertions, 0 deletions
diff --git a/docs/type_system/empty.md b/docs/type_system/empty.md
index ab0226d..55bdcf1 100644
--- a/docs/type_system/empty.md
+++ b/docs/type_system/empty.md
@@ -5,3 +5,19 @@
Container type can be null
## Use with `Option` Union
+
+```text
+make_array : Fn[yes] $ (
+ ? yes {
+ `some Array $ (1; 2; 3)
+ `nome
+ }
+)
+v : make_array(...) // Empty[Array[I64]] $ .none OR Empty[Array[I64]] $ (.some : (1; 2; 3))
+# v {
+ .some {[x] `log x } // Array[I64] $ (1; 2; 3)
+ .none { ... }
+}
+// same as above
+? v {[x] `log x } // Array[I64] $ (1; 2; 3)
+```