ableos/src/lib.rs

32 lines
509 B
Rust
Raw Normal View History

2023-04-17 07:31:18 -05:00
pub mod bytecode;
2023-04-18 18:08:30 -05:00
pub mod engine;
use bytecode::ops::*;
use bytecode::types::{CONST_F64, CONST_U8};
use engine::Engine;
2023-04-17 07:31:18 -05:00
pub struct Page {
2023-04-18 18:08:30 -05:00
pub data: [u8; 4096 * 2],
2023-04-17 07:31:18 -05:00
}
pub fn time() -> u32 {
9
}
2023-04-18 18:08:30 -05:00
#[derive(Debug)]
2023-04-17 07:31:18 -05:00
pub enum RuntimeErrors {
InvalidOpcode(u8),
RegisterTooSmall,
}
// If you solve the halting problem feel free to remove this
pub enum HaltStatus {
Halted,
Running,
}
pub struct HandSide {
signed: bool,
2023-04-18 18:08:30 -05:00
float: bool,
2023-04-17 07:31:18 -05:00
num8: Option<u8>,
num64: Option<u64>,
}