diff options
author | A404M <ahmadmahmoudiprogrammer@gmail.com> | 2025-02-21 23:53:32 +0330 |
---|---|---|
committer | A404M <ahmadmahmoudiprogrammer@gmail.com> | 2025-02-21 23:53:32 +0330 |
commit | 30210fac06a6719a1f547a8cd1e24c159d7e7ee7 (patch) | |
tree | 90900f516383f26d8ffd74aed4b800ac62e685a9 /test | |
parent | 13156d99a29ba927f64d344cf4d385414bcf61e1 (diff) |
add a lot of goodies in types
Diffstat (limited to 'test')
-rw-r--r-- | test/main.felan | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/test/main.felan b/test/main.felan index 387bd90..b14a3ee 100644 --- a/test/main.felan +++ b/test/main.felan @@ -1,9 +1,17 @@ -test :: ()->void; - -main : test : () -> void { - a := 10; +main :: () -> void { + a :theType= 10; while a > 0 { print_u64 1; a = a -1; } }; + +theType :: getType(u64,i64); +signed :: true; + +getType :: (a:type,b:type)->type { + if signed + return a; + else + return b; +}; |