vyre_reference/primitive/bitwise/xor/mod.rs
1//! Dual CPU references for `primitive.bitwise.xor`.
2
3use crate::dual::DualReference;
4use vyre::ops::primitive::bitwise::xor::Xor;
5
6/// Operation ID for the XOR primitive — re-exports the canonical id from the op's `OpSpec`
7/// so the two never drift. If the op's id changes, this constant changes in the same commit.
8pub const OP_ID: &str = Xor::SPEC.id();
9
10/// Direct word-oriented XOR reference.
11pub mod reference_a;
12/// Bit-by-bit XOR reference.
13pub mod reference_b;
14
15/// Dual-reference marker for the XOR primitive.
16pub struct XorDualReference;
17
18impl DualReference for XorDualReference {
19 fn reference_a(input: &[u8]) -> Vec<u8> {
20 reference_a::reference(input)
21 }
22
23 fn reference_b(input: &[u8]) -> Vec<u8> {
24 reference_b::reference(input)
25 }
26}