feo3boy_opcodes/compiler/
mod.rs

1//! This module provides utilities for analyzing and manipulating sequences of
2//! [`Microcode`][crate::microcode::Microcode] operations in order to transform opcodes
3//! into rust code that executes those opcodes.
4use proc_macro2::TokenStream;
5
6pub mod args;
7pub mod direct_executor_generation;
8pub mod instr;
9pub mod state_executor_generation;
10pub mod variables;
11
12/// Which type of microcode operation this is.
13#[derive(Debug, Clone)]
14pub enum OperationType {
15    /// Microcode operation is a pure function.
16    Function {
17        /// Path to the function that defines the microcode operation, relative to the
18        /// module that the Microcode type is defined in.
19        path: TokenStream,
20    },
21    /// Microcode operation is externally defined.
22    Extern,
23}