janhaag/PSE2011 — Issue #87: NPException in Parser
Author: janhaag
Created: 2012-03-04 20:31:04+00:00
State: open
Labels: Parser

The following program throws a NPException:

main() {
int a = --5;
}

java.lang.NullPointerException
at parser.WhileLanguageParser.add_expression(WhileLanguageParser.java:2908)
at parser.WhileLanguageParser.rel_expression(WhileLanguageParser.java:2676)
at parser.WhileLanguageParser.expression(WhileLanguageParser.java:2570)
at parser.WhileLanguageParser.variable_declaration(WhileLanguageParser.java:1893)
at parser.WhileLanguageParser.statement(WhileLanguageParser.java:1093)
at parser.WhileLanguageParser.main_body(WhileLanguageParser.java:762)