Skip to content

Latest commit

 

History

History
27 lines (17 loc) · 6.91 KB

README.md

File metadata and controls

27 lines (17 loc) · 6.91 KB

bfts

CI

Type-level Brainfuck interpreter.

Playground

Example

import type { Interpret } from "bfts";

type Result1 = Interpret<"++++[>+++++<-]>--.">;
// type Result1 = "\u0012"

type Result2 = Interpret<"+++++++++[>++++++++>+++++++++++>+++>+<<<<-]>.>++.+++++++..+++.>+++++.<<+++++++++++++++.>.+++.------.--------.>+.>+.">;
// type Result2 = "Hello World!\n"

// With input
type Result3 = Interpret<",+>,+>,+<<.>.>.", "ABC">;
// type Result3 = "BCD"

License

MIT