Sprache Part 12: Ref, Named, End, Not, Except, Then, Where, Preview, Concat
This is the last in a series of posts documenting Sprache. This post covers a number of less frequently used methods not already covered in other posts.
CommentParser
and Commented
, which are helpers for parsing comments.
Optional
and XOptional
which are helper methods for parsing optional elements.
Positioned
method, intended to allow parsers to return information about the position of parsed elements in the input. To use this, the types returned by the parser must implement the IPositionAware
interface. The below example implements a very simple expression parser which also returns permission information.
Token
, Contained
, Identifier
and LineTerminator
helpers.