Skip to content

Commit

Permalink
#99 Seems QDox 2.0.1 has issue parsing parameter names named "recordL…
Browse files Browse the repository at this point in the history
…ist"
  • Loading branch information
rfscholte committed Jul 28, 2022
1 parent c887457 commit c57b152
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/grammar/lexer.flex
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ JavadocEnd = "*"+ "/"
pushState(NAME);
return Parser.ENUM;
}
"record" / {WhiteSpace}* {Id} {
"record" / {WhiteSpace}+ {Id} {
markAnnotatedElementLine();
classDepth++;
braceMode = CODEBLOCK;
Expand Down
8 changes: 8 additions & 0 deletions src/test/java/com/thoughtworks/qdox/RecordsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -164,4 +164,12 @@ public void recordAsTypeAndIdentifiers() {
+ "}";
builder.addSource( new StringReader(source) );
}

@Test
public void parametersContainingRecord() {
String source = "interface Example{\n"
+ " void apply(Object recordList);"
+ "}";
builder.addSource( new StringReader(source) );
}
}

0 comments on commit c57b152

Please sign in to comment.