public class ParseResult<A> extends Object
A
.
Whenever we parse something, there are two pieces of information
which are immediately of interest:
ParseResult
combines the above two pieces of information into a single class.Constructor and Description |
---|
ParseResult(A result,
int nextPos) |
public ParseResult(A result, int nextPos)
result
- The value which was parsed in (e.g., an AST, an operator, etc.)nextPos
- The next position in the input where to start parsingpublic A getResult()
public int getNextPos()