Packages

p

swam.util

pretty

package pretty

Implementation of a pretty printer inspired by Wadler's one and adapted to strict language (port of https://github.com/kfl/wpp).

Source
package.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. pretty
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Type Members

  1. sealed trait Doc extends AnyRef

    A pretty-printed document that can then be rendered to a certain witdh.

  2. trait Pretty[-T] extends AnyRef

    Typeclass for types that can be pretty-printed.

    Typeclass for types that can be pretty-printed.

    Annotations
    @implicitNotFound("No idea how to pretty-print a ${T}")
  3. implicit final class PrettyOps[T] extends AnyVal

Value Members

  1. def break(sp: Int, off: Int): Doc
  2. def concat(ds: Seq[Doc]): Doc
  3. val empty: Doc
  4. def fromConv[T](conv: (T) => String, t: T): Doc
  5. def group(d: Doc): Doc
  6. def int(i: Int): Doc
  7. val line: Doc
  8. def nest(indent: Int, d: Doc): Doc
  9. val newline: Doc
  10. def seq[T](sep: Doc, render: (T) => Doc, ts: Seq[T]): Doc
  11. def seq(sep: Doc, ts: Seq[Doc]): Doc
  12. def seq[T](sep: Doc, ts: Seq[T])(implicit T: Pretty[T]): Doc
  13. val space: Doc
  14. def str(t: String): Doc
  15. implicit object DocPretty extends Pretty[Doc]
  16. implicit object IntPretty extends Pretty[Int]

Inherited from AnyRef

Inherited from Any

Ungrouped