/// Pretty print with a maximum line length.
///
/// This gives you a nice, indented, pretty-printed s-expression.
///
/// # Example
/// ```
/// # use egg::*;
/// let e: RecExpr<SymbolLang> = "(* (+ 2 2) (+ x y))".parse().unwrap();
/// assert_eq!(e.pretty(10), "
/// (*
///   (+ 2 2)
///   (+ x y))
/// ".trim());
/// ```
Pretty print with a maximum line length.
This gives you a nice, indented, pretty-printed s-expression.
Pretty print with a maximum line length . This gives you a nice indented pretty - printed s - expression .
pub fn pretty(&self, width: usize) -> String {
        let sexp = self.to_sexp();
        let mut buf = String::new();
        pretty_print(&mut buf, &sexp, width, 1).unwrap();
        buf
    }
pub fn pretty ( & self , width : usize ) -> String { let sexp = self . to_sexp ( ) ; let mut buf = String :: new ( ) ; pretty_print ( & mut buf , & sexp , width , 1 ) . unwrap ( ) ; buf }
Pretty print with a maximum line length.
Pretty print with a maximum line length .
&self
width
usize
example
None
use egg::*;
None