scala.util.parsing.combinator.lexical
Type members
Classlikes
This component complements the
common operations for lexical parsers.
Scanners
component withcommon operations for lexical parsers.
Refer to scala.util.parsing.combinator.lexical.StdLexical
for a concrete implementation for a simple, Scala-like language.
for a concrete implementation for a simple, Scala-like language.
This component provides core functionality for lexical parsers.
See its subclasses scala.util.parsing.combinator.lexical.Lexical and -- most interestingly
scala.util.parsing.combinator.lexical.StdLexical, for more functionality.
scala.util.parsing.combinator.lexical.StdLexical, for more functionality.
This component provides a standard lexical parser for a simple,
Scala-like language. It parses keywords and
identifiers, numeric literals (integers), strings, and delimiters.
Scala-like language. It parses keywords and
identifiers, numeric literals (integers), strings, and delimiters.
To distinguish between identifiers and keywords, it uses a set of
reserved identifiers: every string contained in
as a keyword token. (Note that
Additionally, the kinds of delimiters can be specified by the
reserved identifiers: every string contained in
reserved
is returnedas a keyword token. (Note that
=>
is hard-coded as a keyword.)Additionally, the kinds of delimiters can be specified by the
delimiters
set.Usually this component is used to break character-based input into
bigger tokens, which are then passed to a token-parser (see
scala.util.parsing.combinator.syntactical.TokenParsers.)
bigger tokens, which are then passed to a token-parser (see
scala.util.parsing.combinator.syntactical.TokenParsers.)