class MyDecafLexer extends DecafLexer
| Constructor and Description |
|---|
MyDecafLexer() |
| Modifier and Type | Method and Description |
|---|---|
Queue<Token> |
lex(BufferedReader input,
String filename)
Perform lexical analysis, converting Decaf source code into a stream of
Token objects. |
addIgnoredPattern, addTokenPattern, discardIgnored, extract, getLastMatch, lex, lex, lex, nextTokenpublic Queue<Token> lex(BufferedReader input, String filename) throws IOException, InvalidTokenException
Token objects.lex in class DecafLexerinput - Input text readerfilename - Source file name (for source info)IOException - Thrown if there is an error reading from the inputInvalidTokenException - Thrown if an invalid token is encounteredCopyright © 2019. All rights reserved.