[This is preliminary documentation and is subject to change.]
Parses the text of a source file with this SyntaxParser.
Parameters
- sourceFile (String)
- The full path and file name of the file containing the source text to parse.
- restartSymbols (String)
- A string containing a set of restart symbols separated by white space. These are used to indicate where to restart parsing after a syntax error. Parsing restarts on the token AFTER the given symbols, so these should typically be statement terminators or end group symbols.
Return Value
Either a ProductionToken containing an abstract
syntax tree if parsing succeeded, or an ErrorToken if any
syntax errors occurred. The ErrorToken can contain either a single error of
a collection of errors.