The progressive, concatenative, stack-based programming language to rival verbosity and complexity.
Install Zig in whichever way you normally do.
git clone https://github.com/irishgreencitrus/amanatsu
cd amanatsu
zig build
The binary will then be in zig-out/bin/
.
amanatsu name-of-program.amnt
No hidden control flow
If something doesn't look like it calls a function, it doesn't.
"Hello World" print
Does "Hello World"
look like a function? No it doesn't, so it is not a function
Does print
look like a function? It does, so it is a function.
A variable is just a function that places its contents upon the stack.
A function is just a variable that executes its contents.
A functions contents is the same as a variable.
There is no special syntax to define a function.
:my_fav_num 42 define
:my_hello_func [
"Hello World" print
] define
They both use the define
statement in the same way.
The only difference is a function contains multiple instructions whereas a variable contains one.
3 4 + 8 * print
Maths is finally readable.
No order of operations.
In programming, you should not have to worry about how something happens, only what happens. This should extend to maths as well.
We don't care the specifics of how the print
function works, or how the stack works in the source code, but we know print
prints to the screen and that's enough.
Everything is dynamic when it eases development, and not when it doesn't make sense to.
You should be able to print
any value without a formatter, but not apply a +
to something that isn't a number.
Amanatsu is designed for months to come, and will improve as long as I can be bothered.