From 21d0fe6f99c81308fdb392ff8033f09dff90c46c Mon Sep 17 00:00:00 2001 From: Sophie Forrest Date: Fri, 4 Oct 2024 23:46:26 +1300 Subject: feat(instruction): add derives --- src/instruction.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/instruction.rs b/src/instruction.rs index d3aa725..4a23992 100644 --- a/src/instruction.rs +++ b/src/instruction.rs @@ -10,7 +10,7 @@ pub enum Instruction { } /// Addressing modes for MOS 6502. -#[derive(Clone, Copy, Debug)] +#[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum AddressingMode { /// Immediate mode Immediate, @@ -23,6 +23,7 @@ pub enum AddressingMode { } /// Operation retrieved from decoding an opcode. +#[derive(Clone, Copy, Debug, Eq, PartialEq)] pub struct Operation { /// [`AddressingMode`] pub addressing_mode: AddressingMode, -- cgit 1.4.1