class BabelExporter extends AnyRef
Exports lambda expressions in the Babel format. You probably do not want to use this class, use one of expression.toString, .toSigRelativeString, or .toAsciiString instead. These are all implemented using this class.
- Source
- export.scala
- Alphabetic
- By Inheritance
- BabelExporter
- AnyRef
- Any
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
BabelExporter(unicode: Boolean, sig: BabelSignature, omitTypes: Boolean = false)
- unicode
Whether to output logical connectives using Unicode symbols.
- sig
The Babel signature, to decide whether we need to escape constants because they do not fit the naming convention.
Type Members
- sealed trait IdentShowMode extends AnyRef
- case class Parenable(prec: Int, doc: Doc) extends Product with Serializable
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
def
+(other: String): String
- Implicit
- This member is added by an implicit conversion from BabelExporter to any2stringadd[BabelExporter] performed by method any2stringadd in scala.Predef.
- Definition Classes
- any2stringadd
-
def
->[B](y: B): (BabelExporter, B)
- Implicit
- This member is added by an implicit conversion from BabelExporter to ArrowAssoc[BabelExporter] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- Annotations
- @inline()
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- val asciiUnquotName: Regex
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate() @throws( ... )
- val defaultIndent: Int
-
def
ensuring(cond: (BabelExporter) ⇒ Boolean, msg: ⇒ Any): BabelExporter
- Implicit
- This member is added by an implicit conversion from BabelExporter to Ensuring[BabelExporter] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: (BabelExporter) ⇒ Boolean): BabelExporter
- Implicit
- This member is added by an implicit conversion from BabelExporter to Ensuring[BabelExporter] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: Boolean, msg: ⇒ Any): BabelExporter
- Implicit
- This member is added by an implicit conversion from BabelExporter to Ensuring[BabelExporter] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
def
ensuring(cond: Boolean): BabelExporter
- Implicit
- This member is added by an implicit conversion from BabelExporter to Ensuring[BabelExporter] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def export(ty: Ty): String
- def export(sequent: HOLSequent): String
- def export(expr: Expr): String
-
def
formatted(fmtstr: String): String
- Implicit
- This member is added by an implicit conversion from BabelExporter to StringFormat[BabelExporter] performed by method StringFormat in scala.Predef.
- Definition Classes
- StringFormat
- Annotations
- @inline()
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def getIdentShowMode(expr: VarOrConst, knownType: Boolean, bound: Set[String], t0: Map[String, VarOrConst]): (IdentShowMode, Map[String, VarOrConst])
-
def
group(doc: Doc): Doc
- Attributes
- protected
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val lineWidth: Int
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def nest(doc: Doc, j: Int = defaultIndent): Doc
- def notationForConst(const: ConstName): Option[Notation]
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def paramsNecessary(sigC: Const): Boolean
-
def
parens(doc: Doc): Doc
- Attributes
- protected
- val safeChars: Regex
- def safeMatching(c1: Const, c2: Const): Option[Substitution]
- def safeMatching(c1: Const, c2: Expr): Option[Substitution]
- def sepByComma(args: List[Doc]): Doc
- def show(ty: Ty, needParens: Boolean): Doc
- def show(ident: VarOrConst, mode: IdentShowMode): Parenable
-
def
show(expr: Expr, knownType: Boolean, bound: Set[String], t0: Map[String, VarOrConst]): (Parenable, Map[String, VarOrConst])
Converts a lambda expression into a document.
Converts a lambda expression into a document.
At every point in the conversion, we keep track of:
- Whether the parser will already know the type of this expression (by inference)
- What type the free identifiers have.
- What priority the enclosing operator has.
- expr
The lambda expression to convert.
- knownType
Whether we already know the type of this expression.
- bound
Names bound by enclosing binders.
- t0
Already known free identifiers, together with the variable or constant they represent.
- returns
Pretty-printed document and the free identifiers.
- def show(sequent: HOLSequent, bound: Set[String], t0: Map[String, VarOrConst]): (Doc, Map[String, VarOrConst])
- def showApps(expr: Expr, knownType: Boolean, bound: Set[String], t0: Map[String, VarOrConst]): (Parenable, Map[String, VarOrConst])
- def showFakeBin(expr: Expr, fakeConst: ConstName, a: Expr, b: Expr, knownType: Boolean, bound: Set[String], t0: Map[String, VarOrConst]): (Parenable, Map[String, VarOrConst])
- def showName(name: String): Doc
- def showName(token: Token)(implicit dummyImplicit: DummyImplicit): Doc
- def showNameFollowableByOp(name: String): Doc
- def showNameWithParams(name: String, params: List[Ty]): Doc
- def showNonOpName(name: String): Doc
- def showTyParams(params: List[Ty], always: Boolean = false): Doc
- def shows(exprs: List[Expr], knownType: Boolean, bound: Set[String], t0: Map[String, VarOrConst]): (List[Parenable], Map[String, VarOrConst])
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
- def unicodeSafe(n: Token): Boolean
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
→[B](y: B): (BabelExporter, B)
- Implicit
- This member is added by an implicit conversion from BabelExporter to ArrowAssoc[BabelExporter] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- object Bare extends IdentShowMode with Product with Serializable
- object Safe extends IdentShowMode with Product with Serializable
- object WithParams extends IdentShowMode with Product with Serializable
- object WithType extends IdentShowMode with Product with Serializable
This is the API documentation for GAPT.
The main package is gapt.