Packages

t

org.kiama.util

Compiler

trait Compiler[T <: Attributable] extends CompilerWithConfig[T, Config]

Specialisation of CompilerWithConfig that uses the default configuration type.

Source
Compiler.scala
Linear Supertypes
CompilerWithConfig[T, Config], RegexParsers, Parsers, CompilerBase[T, Config], Profiler, bitbucket.inkytonik.dsprofile.Profiler, Values, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Compiler
  2. CompilerWithConfig
  3. RegexParsers
  4. Parsers
  5. CompilerBase
  6. Profiler
  7. Profiler
  8. Values
  9. AnyRef
  10. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type Elem = Char
    Definition Classes
    RegexParsers → Parsers
  2. case class Error extends NoSuccess with Product with Serializable
    Definition Classes
    Parsers
  3. case class Failure extends NoSuccess with Product with Serializable
    Definition Classes
    Parsers
  4. type Input = Reader[Elem]
    Definition Classes
    Parsers
  5. sealed abstract class NoSuccess extends ParseResult[Nothing]
    Definition Classes
    Parsers
  6. trait OnceParser[+T] extends Parser[T]
    Definition Classes
    Parsers
  7. sealed abstract class ParseResult[+T] extends AnyRef
    Definition Classes
    Parsers
  8. abstract class Parser[+T] extends (Input) ⇒ ParseResult[T]
    Definition Classes
    Parsers
  9. case class Record extends Product with Serializable
    Definition Classes
    Values
  10. case class Success[+T] extends ParseResult[T] with Product with Serializable
    Definition Classes
    Parsers
  11. case class ~[+a, +b] extends Product with Serializable
    Definition Classes
    Parsers
  12. case class Child (i: Int) extends Step with Product with Serializable

    A step to child i of the current node, counting from zero.

    A step to child i of the current node, counting from zero.

    Definition Classes
    Profiler
  13. case class Dep (step: Step, tipe: Value, attribute: Value) extends Product with Serializable

    Dependence record saying that the source attribute depends on attribute of a node with type type that is the given step away.

    Dependence record saying that the source attribute depends on attribute of a node with type type that is the given step away.

    Definition Classes
    Profiler
  14. abstract class Step extends AnyRef

    A single step in the evaluation of an attribute.

    A single step in the evaluation of an attribute.

    Definition Classes
    Profiler

Abstract Value Members

  1. abstract def parser: Parser[T]

    The actual parser used to produce the AST.

    The actual parser used to produce the AST.

    Definition Classes
    CompilerWithConfig

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def OnceParser[T](f: (Input) ⇒ ParseResult[T]): Parser[T] with OnceParser[T]
    Definition Classes
    Parsers
  5. def Parser[T](f: (Input) ⇒ ParseResult[T]): Parser[T]
    Definition Classes
    Parsers
  6. def accept[U](expected: String, f: PartialFunction[Elem, U]): Parser[U]
    Definition Classes
    Parsers
  7. def accept[ES](es: ES)(implicit arg0: (ES) ⇒ List[Elem]): Parser[List[Elem]]
    Definition Classes
    Parsers
  8. implicit def accept(e: Elem): Parser[Elem]
    Definition Classes
    Parsers
  9. def acceptIf(p: (Elem) ⇒ Boolean)(err: (Elem) ⇒ String): Parser[Elem]
    Definition Classes
    Parsers
  10. def acceptMatch[U](expected: String, f: PartialFunction[Elem, U]): Parser[U]
    Definition Classes
    Parsers
  11. def acceptSeq[ES](es: ES)(implicit arg0: (ES) ⇒ Iterable[Elem]): Parser[List[Elem]]
    Definition Classes
    Parsers
  12. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  13. def chainl1[T, U](first: ⇒ Parser[T], p: ⇒ Parser[U], q: ⇒ Parser[(T, U) ⇒ T]): Parser[T]
    Definition Classes
    Parsers
  14. def chainl1[T](p: ⇒ Parser[T], q: ⇒ Parser[(T, T) ⇒ T]): Parser[T]
    Definition Classes
    Parsers
  15. def chainr1[T, U](p: ⇒ Parser[T], q: ⇒ Parser[(T, U) ⇒ U], combine: (T, U) ⇒ U, first: U): Parser[U]
    Definition Classes
    Parsers
  16. def checkFor(record: Record, dim: Dimension, eventtype: String, needed: Dimension)(f: (Value) ⇒ Value): Value
    Definition Classes
    Values
  17. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  18. def commit[T](p: ⇒ Parser[T]): Parser[T]
    Definition Classes
    Parsers
  19. def createConfig(args: Seq[String], output: Emitter = new OutputEmitter, error: Emitter = new ErrorEmitter): Config

    Create the configuration for a particular run of the compiler.

    Create the configuration for a particular run of the compiler. If supplied, use emitter instead of a standard output emitter.

    Definition Classes
    CompilerCompilerBase
  20. def dimValue(record: Record, dim: Dimension): Value

    Support Kiama-specific profiling dimensions.

    Support Kiama-specific profiling dimensions.

    Definition Classes
    Profiler → Profiler → Values
  21. def driver(args: Seq[String]): Unit

    Driver for this compiler.

    Driver for this compiler. First, use the argument list to create a configuration for this execution. Then, use the configuration to run the file processing in the appropriate way.

    Definition Classes
    CompilerBase
  22. def elem(e: Elem): Parser[Elem]
    Definition Classes
    Parsers
  23. def elem(kind: String, p: (Elem) ⇒ Boolean): Parser[Elem]
    Definition Classes
    Parsers
  24. def encoding: String

    The character encoding of input files read by this compiler.

    The character encoding of input files read by this compiler. Defaults to UTF-8.

    Definition Classes
    CompilerBase
  25. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  26. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  27. def err(msg: String): Parser[Nothing]
    Definition Classes
    Parsers
  28. def failure(msg: String): Parser[Nothing]
    Definition Classes
    Parsers
  29. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  30. def finishReport(): Unit
    Definition Classes
    Values
  31. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
  32. def guard[T](p: ⇒ Parser[T]): Parser[T]
    Definition Classes
    Parsers
  33. def handleWhiteSpace(source: CharSequence, offset: Int): Int
    Attributes
    protected
    Definition Classes
    RegexParsers
  34. def hashCode(): Int
    Definition Classes
    AnyRef → Any
  35. def includeTimings: Boolean
    Definition Classes
    Profiler
  36. def isEventType(record: Record, eventtype: String): Boolean
    Definition Classes
    Values
  37. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  38. implicit def literal(s: String): Parser[String]
    Definition Classes
    RegexParsers
  39. def log[T](p: ⇒ Parser[T])(name: String): Parser[T]
    Definition Classes
    Parsers
  40. def main(args: Array[String]): Unit

    The entry point for this compiler.

    The entry point for this compiler.

    Definition Classes
    CompilerBase
  41. def makeast(reader: Reader, filename: String, config: Config): Either[T, String]

    Make an AST by running the parser, reporting errors if the parse fails.

    Make an AST by running the parser, reporting errors if the parse fails.

    Definition Classes
    CompilerWithConfigCompilerBase
  42. def mkList[T]: (~[T, List[T]]) ⇒ List[T]
    Definition Classes
    Parsers
  43. def nanoToMs(nano: Long): Long
    Definition Classes
    Profiler
  44. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  45. def not[T](p: ⇒ Parser[T]): Parser[Unit]
    Definition Classes
    Parsers
  46. final def notify(): Unit
    Definition Classes
    AnyRef
  47. final def notifyAll(): Unit
    Definition Classes
    AnyRef
  48. def opt[T](p: ⇒ Parser[T]): Parser[Option[T]]
    Definition Classes
    Parsers
  49. def output(str: String): Unit
    Definition Classes
    Values
  50. def outputln(str: String): Unit
    Definition Classes
    Values
  51. def parse[T](p: Parser[T], in: Reader): ParseResult[T]
    Definition Classes
    RegexParsers
  52. def parse[T](p: Parser[T], in: CharSequence): ParseResult[T]
    Definition Classes
    RegexParsers
  53. def parse[T](p: Parser[T], in: Reader[Char]): ParseResult[T]
    Definition Classes
    RegexParsers
  54. def parseAll[T](p: Parser[T], in: CharSequence): ParseResult[T]
    Definition Classes
    RegexParsers
  55. def parseAll[T](p: Parser[T], in: Reader): ParseResult[T]
    Definition Classes
    RegexParsers
  56. def parseAll[T](p: Parser[T], in: Reader[Char]): ParseResult[T]
    Definition Classes
    RegexParsers
  57. def parseProfileOption(value: String): Seq[Dimension]
    Definition Classes
    Profiler
  58. def percent(v: Long, total: Long): String
    Definition Classes
    Profiler
  59. def phrase[T](p: Parser[T]): Parser[T]
    Definition Classes
    RegexParsers → Parsers
  60. def positioned[T <: Positional](p: ⇒ Parser[T]): Parser[T]
    Definition Classes
    RegexParsers → Parsers
  61. def prettyprint(ast: T): String

    Pretty-print an abstract syntax trees.

    Pretty-print an abstract syntax trees. Default: return an empty string.

    Definition Classes
    CompilerBase
  62. def printDependencyGraph(record: Record, dim: Dimension): Unit

    Print the dependency graph for the attribute evaluation represented by record.

    Print the dependency graph for the attribute evaluation represented by record. The output is in dot form.

    Definition Classes
    Profiler
  63. def printReports(totalTime: Long, dimensionNames: Seq[Dimension], records: List[Record]): Unit
    Definition Classes
    Profiler
  64. val printTables: Boolean
    Definition Classes
    Values
  65. def process(filename: String, ast: T, config: Config): Unit

    Process the AST by performing any processing at the next level up and then initialising the AST for attribution.

    Process the AST by performing any processing at the next level up and then initialising the AST for attribution.

    Definition Classes
    CompilerWithConfigCompilerBase
  66. def processfile(filename: String, config: Config): Unit

    Process a file argument by using makeast to turn their contents into abstract syntax trees (ASTs) and then by process which conducts arbitrary processing on the ASTs.

    Process a file argument by using makeast to turn their contents into abstract syntax trees (ASTs) and then by process which conducts arbitrary processing on the ASTs. The character encoding of the files is given by the encoding method.

    Definition Classes
    CompilerBase
  67. def processfiles(filenames: Seq[String], config: Config): Unit

    Process the files one by one.

    Process the files one by one.

    Definition Classes
    CompilerBase
  68. def profile[T](computation: ⇒ T, dimensionNames: Seq[Dimension], logging: Boolean): T
    Definition Classes
    Profiler
  69. def profileStart(logging: Boolean): Unit
    Definition Classes
    Profiler
  70. def profileStop(): (Seq[Dimension]) ⇒ Unit
    Definition Classes
    Profiler
  71. def profileStop(dimensionNames: Seq[Dimension]): Unit
    Definition Classes
    Profiler
  72. def profileStopInteractive(): Unit
    Definition Classes
    Profiler
  73. implicit def regex(r: Regex): Parser[String]
    Definition Classes
    RegexParsers
  74. def rep[T](p: ⇒ Parser[T]): Parser[List[T]]
    Definition Classes
    Parsers
  75. def rep1[T](first: ⇒ Parser[T], p0: ⇒ Parser[T]): Parser[List[T]]
    Definition Classes
    Parsers
    Annotations
    @migration
    Migration

    (Changed in version 2.9.0) The p0 call-by-name arguments is evaluated at most once per constructed Parser object, instead of on every need that arises during parsing.

  76. def rep1[T](p: ⇒ Parser[T]): Parser[List[T]]
    Definition Classes
    Parsers
  77. def rep1sep[T](p: ⇒ Parser[T], q: ⇒ Parser[Any]): Parser[List[T]]
    Definition Classes
    Parsers
  78. def repN[T](num: Int, p: ⇒ Parser[T]): Parser[List[T]]
    Definition Classes
    Parsers
  79. def repsep[T](p: ⇒ Parser[T], q: ⇒ Parser[Any]): Parser[List[T]]
    Definition Classes
    Parsers
  80. def skipWhitespace: Boolean
    Definition Classes
    RegexParsers
  81. def startReport(dimensionNames: Seq[Dimension]): Unit

    Take any actions that need to be done at the start of reporting.

    Take any actions that need to be done at the start of reporting.

    Definition Classes
    Profiler → Values
  82. val startTime: Long
    Definition Classes
    Profiler
  83. def subjectsToStep(src: Any, dst: Any): Step

    Summarise the single step between two nodes at which attributes have been evaluated.

    Summarise the single step between two nodes at which attributes have been evaluated.

    Definition Classes
    Profiler
  84. def success[T](v: T): Parser[T]
    Definition Classes
    Parsers
  85. def summariseAlongDims(dimensionNames: Seq[Dimension], records: List[Record], nrecords: Int, profiledTime: Long): Unit
    Definition Classes
    Profiler
  86. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  87. def time[T](computation: ⇒ T, warmup: Int, n: Int, discard: Int): Unit
    Definition Classes
    Profiler
  88. def toString(): String
    Definition Classes
    AnyRef → Any
  89. def trace(predicate: (Event) ⇒ Boolean): Unit
    Definition Classes
    Profiler
  90. def valueToString(a: Value): String
    Definition Classes
    Values
  91. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  92. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  93. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  94. val whiteSpace: Regex
    Attributes
    protected
    Definition Classes
    RegexParsers
  95. object NoSuccess
    Definition Classes
    Parsers
  96. object Next extends Step with Product with Serializable

    A step to the previous node in a sequence.

    A step to the previous node in a sequence.

    Definition Classes
    Profiler
  97. object Other extends Step with Product with Serializable

    A step to a node that doesn't fit into any of the other categories.

    A step to a node that doesn't fit into any of the other categories. This category will be used for nodes that were obtained as the result of reference attributes or as values that sit outside the main tree.

    Definition Classes
    Profiler
  98. object Parent extends Step with Product with Serializable

    A step to the parent of the current node.

    A step to the parent of the current node.

    Definition Classes
    Profiler
  99. object Prev extends Step with Product with Serializable

    A step to the previous node in a sequence.

    A step to the previous node in a sequence.

    Definition Classes
    Profiler
  100. object Self extends Step with Product with Serializable

    A step nowhere.

    A step nowhere. I.e., the dependent attribute is evaluated at the current node.

    Definition Classes
    Profiler

Inherited from CompilerWithConfig[T, Config]

Inherited from RegexParsers

Inherited from Parsers

Inherited from CompilerBase[T, Config]

Inherited from Profiler

Inherited from bitbucket.inkytonik.dsprofile.Profiler

Inherited from Values

Inherited from AnyRef

Inherited from Any

Ungrouped