pmd: verify #1020 Parsing Error

This commit is contained in:
Andreas Dangel 2013-01-24 18:59:07 +01:00
parent e0b7f6f17c
commit d557ed9c01
2 changed files with 28 additions and 0 deletions

View File

@ -3,6 +3,7 @@
Fixed bug 878: False positive: UnusedFormalParameter for abstract methods
Fixed bug 913: SignatureDeclareThrowsException is raised twice
Fixed bug 1012: False positive: Useless parentheses.
Fixed bug 1020: Parsing Error
Fixed bug 1026: PMD doesn't handle 'value =' in SuppressWarnings annotation
Fixed bug 1037: Facing a showstopper issue in PMD Report Class (report listeners)
Fixed bug 1043: node.getEndLine() always returns 0 (ECMAscript)

View File

@ -95,4 +95,31 @@ class PmdTestChild extends PmdTestParent {
}
});
}
}
/*
* Test cases for bug #1020 Parsing Error
*/
class SimpleBean {
String name;
}
class SimpleBeanUser {
SimpleBeanUser(SimpleBean o) {
}
SimpleBeanUser() {
this(new SimpleBean() {{
name = "test";
}});
}
}
class SimpleBeanUser2 extends SimpleBeanUser {
SimpleBeanUser2() {
super(new SimpleBean(){{
name = "test2";
}});
}
}