Created
September 28, 2023 11:27
-
-
Save Pavel-Durov/44dd21c246cb199ecb35a2cf31aa816f to your computer and use it in GitHub Desktop.
Writing an Interpreter in Rust: Bytecode and Stack-based VM - instruction.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[derive(Debug, PartialEq, Clone)] | |
pub enum Op { | |
Add, // Addition operation | |
Mull, // Multiplication operation | |
Push { value: u64 }, // Load numeric value onto stack | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment