fn log_message(self) {
        match self {
            EditSuccess::Undo => log::info!("Undoing one change"),
            EditSuccess::Redo => log::info!("Redoing one change"),
            EditSuccess::Move(n, Direction::Up) => log::info!("Moving {} levels up the tree", n),
            EditSuccess::Move(n, Direction::Down) => {
                log::info!("Moving {} levels down the tree", n)
            }
            EditSuccess::Move(n, Direction::Prev) => {
                log::info!("Moving to {}th previous sibling", n)
            }
            EditSuccess::Move(n, Direction::Next) => log::info!("Moving to {}th next sibling", n),
            EditSuccess::Replace(class) => {
                log::info!("Replacing with '{}'/{}", class.to_char(), class.name())
            }
            EditSuccess::InsertChild(class) => {
                log::info!(
                    "Inserting '{}'/{} as new child",
                    class.to_char(),
                    class.name()
                )
            }
            EditSuccess::InsertNextToCursor { side, class } => log::info!(
                "Inserting '{}'/{} {} the cursor",
                class.to_char(),
                class.name(),
                side.relational_word()
            ),
            EditSuccess::Delete { name } => log::info!("Deleting {}", name),
        }
    }
/// Writes an info message of a successful action using `info!`
Writes an info message of a successful action using `info!`
Writes an info message of a successful action using ` info! `
fn log_message(self) {
        match self {
            EditSuccess::Undo => log::info!("Undoing one change"),
            EditSuccess::Redo => log::info!("Redoing one change"),
            EditSuccess::Move(n, Direction::Up) => log::info!("Moving {} levels up the tree", n),
            EditSuccess::Move(n, Direction::Down) => {
                log::info!("Moving {} levels down the tree", n)
            }
            EditSuccess::Move(n, Direction::Prev) => {
                log::info!("Moving to {}th previous sibling", n)
            }
            EditSuccess::Move(n, Direction::Next) => log::info!("Moving to {}th next sibling", n),
            EditSuccess::Replace(class) => {
                log::info!("Replacing with '{}'/{}", class.to_char(), class.name())
            }
            EditSuccess::InsertChild(class) => {
                log::info!(
                    "Inserting '{}'/{} as new child",
                    class.to_char(),
                    class.name()
                )
            }
            EditSuccess::InsertNextToCursor { side, class } => log::info!(
                "Inserting '{}'/{} {} the cursor",
                class.to_char(),
                class.name(),
                side.relational_word()
            ),
            EditSuccess::Delete { name } => log::info!("Deleting {}", name),
        }
    }
fn log_message ( self ) { match self { EditSuccess :: Undo => log :: info ! ( " " ) , EditSuccess :: Redo => log :: info ! ( " " ) , EditSuccess :: Move ( n , Direction :: Up ) => log :: info ! ( " " n ) , EditSuccess :: Move ( n , Direction :: Down ) => { log :: info ! ( " " n ) } EditSuccess :: Move ( n , Direction :: Prev ) => { log :: info ! ( " " n ) } EditSuccess :: Move ( n , Direction :: Next ) => log :: info ! ( " " n ) , EditSuccess :: Replace ( class ) => { log :: info ! ( " " class to_char ( ) class name ( ) ) } EditSuccess :: InsertChild ( class ) => { log :: info ! ( " " class to_char ( ) class name ( ) ) } EditSuccess :: InsertNextToCursor { side , class } => log :: info ! ( " " class to_char ( ) class name ( ) side relational_word ( ) ) , EditSuccess :: Delete { name } => log :: info ! ( " " name ) , } }
Writes an info message of a successful action using `info!`
Writes an info message of a successful action using ` info! `
self
self