rust/example/std_example.rs
2019-07-26 11:28:04 +02:00

26 lines
386 B
Rust

#![feature(core_intrinsics)]
use std::io::Write;
fn main() {
assert_eq!((1u128 + 2) as u16, 3);
}
#[derive(PartialEq)]
enum LoopState {
Continue(()),
Break(())
}
pub enum Instruction {
Increment,
Loop,
}
fn map(a: Option<(u8, Box<Instruction>)>) -> Option<Box<Instruction>> {
match a {
None => None,
Some((_, instr)) => Some(instr),
}
}