NanoML is a simple eager functional programming language based on MiniML from The Programming Language Zoo
NanoML written on F#. Lexing and parsing done by fslex and fsyacc. Runtime is a simple SECD virtual machine.
NanoML has 4 types int, float, bool, (* -> *). Language hasn't type inference at all. But type checker statically check all types in program.
Language support functions, values, recursion, closures.
Also language provides with simple interpreter shell.
Below is a classical example recursive factorial function:
let fact =
fun f (n : int) : int =>
if n = 0 then 1
else n * f (n - 1)
end;;
To see more NanoML code check stdlib.nanoml which contains small set of common and useful functions.
To get full language syntax see NanoMLParser.fsy.