| Crates.io | brainfuck_rs |
| lib.rs | brainfuck_rs |
| version | 2.0.0 |
| created_at | 2016-12-01 20:53:56.497805+00 |
| updated_at | 2019-02-05 13:59:04.518756+00 |
| description | Brainfuck parser and interpreter using nom |
| homepage | |
| repository | https://github.com/Keruspe/brainfuck.rs |
| max_upload_size | |
| id | 7433 |
| size | 26,595 |
Implementation of a brainfuck parser and interpreter written in rust using nom
cargo run --bin bf examples/bottles.bf
extern crate brainfuck;
use brainfuck::context::Context;
use brainfuck::parser;
fn main() {
let hello_world = include_bytes!("hello_world.bf");
let mut ctx = Context::new();
let block = parser::parse(hello_world).expect("Failed parsing input file");
ctx.run(&block);
}
You can run cargo run --example hello_world to try this