[move-prover] moved around display impls
Closes:
@@ -233,15 +233,6 @@ pub enum StrongEdge {
Offset(usize),
}
-impl std::fmt::Display for StrongEdge {
- fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
- match self {
- StrongEdge::Empty => write!(f, "E"),
- StrongEdge::Offset(offset) => write!(f, "{}", offset),
- }
- }
-}
-
/// A borrow edge -- used in memory operations
#[derive(Eq, PartialEq, Debug, Clone)]
pub enum BorrowEdge {
@@ -249,15 +240,6 @@ pub enum BorrowEdge {
Strong(StrongEdge),
}
-impl std::fmt::Display for BorrowEdge {
- fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
- match self {
- BorrowEdge::Weak => write!(f, "*"),
- BorrowEdge::Strong(se) => write!(f, "{}", se),
- }
- }
-}
-
/// A specification property kind.
#[derive(Debug, Clone, Copy, Eq, Ord, PartialEq, PartialOrd)]
pub enum PropKind {
@@ -551,6 +533,24 @@ impl Bytecode {
}
}
+impl std::fmt::Display for BorrowEdge {
+ fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
+ match self {
+ BorrowEdge::Weak => write!(f, "*"),
+ BorrowEdge::Strong(se) => write!(f, "{}", se),
+ }
+ }
+}
+
+impl std::fmt::Display for StrongEdge {
+ fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
+ match self {
+ StrongEdge::Empty => write!(f, "E"),
+ StrongEdge::Offset(offset) => write!(f, "{}", offset),
+ }
+ }
+}
+
/// A display object for a bytecode.
pub struct BytecodeDisplay<'env> {
bytecode: &'env Bytecode,
