scalaParser

package scalaParser

Visibility
  1. Public
  2. All

Type Members

  1. class ScalaSyntax extends Parser with Basic with Identifiers with Literals

    Parser for Scala syntax.

    Parser for Scala syntax.

    The G parameter that gets passed in to each rule stands for "Greedy", and determines whether or not that rule is to consume newlines after the last terminal in that rule. We need to pass it everywhere so it can go all the way to the last terminal deep inside the parse tree, which can then decide whether or not to consume whitespace.

    The vast majority of terminals will consume newlines; only rules which occur in {} blocks won't have their terminals consume newlines, and only the *last* terminal in the rule will be affected. That's why the parser does terminals-consume-newlines-by-default, and leaves it up to the dev to thread the G variable where-ever we want the opposite behavior.

Value Members

  1. package syntax

Ungrouped