Metacharacter
The metacharacters used in message names.
Parameters
The Java String denoting the metacharacter.
Entries
A back-quote (`) precedes a metacharacter to cause it to be treated as an ordinary character. Since no metacharacters are alphanumeric, and since non-alphanumeric characters are always tokenized individually, back-quote only operates on the single character following it. Note that since back-quote is itself a metacharacter, two successive backquotes indicates a single back-quote should be parsed from the Avail source code.
A close-guillemet (») indicates the end of a group or other structure that started with an OPEN_GUILLEMET open-guillemet («).
The double-dagger (‡) is used within a Group to delimit the left part, which repeats, from the right part, which separates occurrences of the left part.
The double-question-mark (⁇) is a single Unicode character (U+2047). It can be placed after a token or after a simple group (a group that has no right side and does not yield anything from its left side). In the case of a token, it allows zero or one occurrences of the token to occur in the Avail source, and discards information about whether the token was encountered. Similarly, when applied to a simple group it accepts zero or one occurrences of the group's left side, discarding the distinction. In both cases, the double-question-mark causes a CompletelyOptional to be built.
The exclamation mark (!) can follow an ELLIPSIS (…) to cause creation of a RawTokenArgument, which matches any token that isn't whitespace or a comment.
When compiling indentation-sensitive languages, this message part matches whitespace that strictly increases the indentation beyond the indentation that was active when starting to parse the message. Note that the start position is not necessarily where the first token of the message occurred, since methods may start with leading arguments. In that case, the indentation refers to the whitespace at the start of the line where that leading argument begins.
When compiling indentation-sensitive languages, this message part matches whitespace that exactly matches the indentation that was active when starting to parse the message. Note that the start position is not necessarily where the first token of the message occurred, since methods may start with leading arguments. In that case, the indentation refers to the whitespace at the start of the line where that leading argument begins.
When compiling indentation-sensitive languages, this message part matches whitespace that does not increase the indentation beyond the indentation that was active when starting to parse the message. It will therefore match either a restoration of the original indentation or an outdent to an even more reduced indentation. Note that the start position is not necessarily where the first token of the message occurred, since methods may start with leading arguments. In that case, the indentation refers to the whitespace at the start of the line where that leading argument begins.
An open-guillemet («) indicates the start of a group or other structure that will eventually end with a CLOSE_GUILLEMET (»).
A question mark (?) may follow a Simple expression, which creates an Optional, which yields a boolean literal indicating whether the token was present or not.
A section sign (§) indicates where, in the parsing of a macro invocation, it should invoke one of its prefix functions. The order of section signs in the method name corresponds with the order of the prefix functions.
A single-dagger (†) following an UNDERSCORE (_) causes creation of an ArgumentInModuleScope. This will parse an expression that does not use any variables in the local scope, then evaluate it and wrap it in a literal.
An Expression followed by a tilde (~) causes all Simple expressions anywhere within it to match case-insensitively to the tokens lexed from the Avail source code. All of these simple expressions are required to be specified in lower case to break a pointless symmetry about how to name the method.
An underscore indicates where a subexpression should be parsed.
If an up-arrow (↑) follows an UNDERSCORE, a VariableQuote is created, which expects a VariableUsePhraseDescriptor, which will be automatically converted into a reference phrase.
The vertical bar (|) separates alternatives within an Alternation. The alternatives may be Simple expressions, or simple Groups (having no double-dagger, and yielding no argument values).
Properties
Functions
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
Returns an array containing the constants of this enum type, in the order they're declared.