Brainfuck interpreter written in Fantom.
How it works
The interpreter parses the source code and transform it to tokens ignoring everything except
After that, it creates an index of brackets to speed the execution of the jumps.
Running a program
To execute a brainfuck program called
fan brainfuck hello.bf
To show debug information use:
fan brainfuck -debug hello.bf
In folder the
res there are some brainfuck programs. I'm sorry I don't remember the source of all of them. There are more examples in: http://esoteric.sange.fi/brainfuck/bf-source/prog/