Basic type conversion when assigning, added + - unary

This commit is contained in:
Krzosa Karol
2022-06-03 10:48:07 +02:00
parent e2e684294e
commit 081e559520
7 changed files with 95 additions and 20 deletions

View File

@@ -46,6 +46,7 @@ For now I don't thing it should be overloadable.
[ ] - Add single line lambda expressions
[ ] - Ternary operator
[ ] - Constants embeded in structs should be able to refer to other constants in that namespace without prefix
[ ] - Converting from U64 token to S64 Atom introduces unnanounced error (negates) - probably need the big int stuff
[ ] - Order independent constants in structs
[ ] - Can you even have recursive lambdas in structs, other recursive stuff
[ ] - Casting to basic types by call S64(x)
@@ -102,16 +103,16 @@ int main(){
String result = {};
#if 1
result = compile_file("globals.kl"_s);
printf("%s", result.str);
result = compile_file("enums.kl"_s);
printf("%s", result.str);
result = compile_file("order1.kl"_s);
printf("%s", result.str);
result = compile_file("lambdas.kl"_s);
printf("%s", result.str);
result = compile_file("order2.kl"_s);
printf("%s", result.str);
// result = compile_file("globals.kl"_s);
// printf("%s", result.str);
// result = compile_file("enums.kl"_s);
// printf("%s", result.str);
// result = compile_file("order1.kl"_s);
// printf("%s", result.str);
// result = compile_file("lambdas.kl"_s);
// printf("%s", result.str);
// result = compile_file("order2.kl"_s);
// printf("%s", result.str);
result = compile_file("new_types.kl"_s);
printf("%s", result.str);
#endif