diff --git a/rust/src/instruction/gate.rs b/rust/src/instruction/gate.rs index aed680c38..93c9bcdf3 100644 --- a/rust/src/instruction/gate.rs +++ b/rust/src/instruction/gate.rs @@ -17,3 +17,13 @@ impl From for quil_rs::instruction::GateModifier { } } } + +impl From for GateModifier { + fn from(modifier: quil_rs::instruction::GateModifier) -> Self { + match modifier { + quil_rs::instruction::GateModifier::Controlled => GateModifier::Controlled, + quil_rs::instruction::GateModifier::Dagger => GateModifier::Dagger, + quil_rs::instruction::GateModifier::Forked => GateModifier::Forked, + } + } +}