Create a token representing an indent. It's not part of the AST and it will be trimmed and merged into adjacent TextElements, or turned into a new TextElement, if it's surrounded by two Placeables.
maybeGetPattern distinguishes between patterns which start on the same line as the identifier (a.k.a. inline signleline patterns and inline multiline patterns) and patterns which start on a new line (a.k.a. block multiline patterns). The distinction is important for the dedentation logic: the indent of the first line of a block pattern must be taken into account when calculating the maximum common indent.
Parse the first Message or Term in source
.
Skip all encountered comments and start parsing at the first Message or Term start. Return Junk if the parsing is not successful.
Preceding comments are ignored unless they contain syntax errors themselves, in which case Junk for the invalid comment is returned.
Dedent a list of elements by removing the maximum common indent from the beginning of text lines. The common indent is calculated in getPattern.