18 lines
349 B
Rust
18 lines
349 B
Rust
![]() |
#[derive(Debug, Copy, Clone, PartialEq)]
|
||
|
pub enum BinaryOperator {
|
||
|
Implication,
|
||
|
Or,
|
||
|
And,
|
||
|
}
|
||
|
|
||
|
impl From<BinaryOperator> for &str {
|
||
|
fn from(op: BinaryOperator) -> Self {
|
||
|
match op {
|
||
|
BinaryOperator::Implication => "=>",
|
||
|
BinaryOperator::Or => "|",
|
||
|
BinaryOperator::And => "&",
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|