Totem-Studios / lotus

Lotus is a type-safe compiled programming languages designed to simplify systems programming, achieving memory safety using RAII.
https://totemstudios.org/lotus
MIT License
4 stars 2 forks source link

Added the modulus operator, casting and support for more types #32

Closed lucasnorman07 closed 1 month ago

lucasnorman07 commented 1 month ago

Implemented casting between f32, f64, integers from i8 up to i64 and bool. I also added the modules operator, and automatic casting in variable definitions like for example:

x: i16 = 435.45;

I also added bit width detection for integer literals, so that they default to i32, but grow to i64 if they get to big.