samlang is a statically-typed functional programming language designed and implemented by Sam Zhou. The language is still under development so the syntax and semantics may be changed at any time.
The language can be compiled down to X86 assembly and machine code.
Here is an example program:
A module contains a list of classes, and a class can either be a normal class or utility class,
which will be explained later. If there is a module named
Main and the module contains a no-arg
main, then the entire program will be evaluated to the evaluation result of the function
Main.main(). If there is no such module, then the evaluation result will be
.sam source file defines a module. You can use a different module's classes by
Cyclic dependencies and mutual recursion between different classes are allowed. However, cyclic dependencies between modules are strongly discouraged.