My WIP hobby programming language implemented in Haskell.

Poorly-drawn Hiss logo

Hiss is my WIP hobby programming language implemented in Haskell. It is named in honor of a copperhead snake discovered in the basement of my parents’ house, which was then serving as my bedroom.

I’m building Hiss to learn more about Haskell, functional programming in general, and in particular, the implementation of functional languages. (So here’s your disclaimer: it’s neither well-tested nor stable and will almost certainly never be recommended for production use.)

Here is a sample Hiss program that computes the Collatz stopping time of 27:

// computes k mod n
mod(n, k) = if k < n
            then k
            else mod(n, k-n)

mod2 = mod(2) // partial application of mod

// returns stopping time of n
collatz(n, steps) = if n == 1
                    then steps
                    else if mod2(n) == 0
                         then collatz(n/2, steps + 1)
                         else collatz(3*n + 1, steps + 1)

main() = collatz(27, 0) // should output 111

Hiss is:

It supports some cool features from functional programming:

The Hiss compiler hissc is written in Haskell and open-sourced on GitHub. hissc is still in progress, but it already includes:

Planned features include: