summaryrefslogtreecommitdiffstats
path: root/sonar-duplications/src/main
diff options
context:
space:
mode:
authorEvgeny Mandrikov <mandrikov@gmail.com>2011-09-27 12:09:18 +0400
committerEvgeny Mandrikov <mandrikov@gmail.com>2011-09-27 12:46:01 +0400
commit24b35ccec51c57c47b301893e46c96c92cfdfe6d (patch)
tree55c9f93fdc74f3de6973381c90ccdcffe7692b10 /sonar-duplications/src/main
parent438d36393d14196284cb4fe11e570c5e4b860d44 (diff)
downloadsonarqube-24b35ccec51c57c47b301893e46c96c92cfdfe6d.tar.gz
sonarqube-24b35ccec51c57c47b301893e46c96c92cfdfe6d.zip
CPD: add support for Java 7 - try with resource
Diffstat (limited to 'sonar-duplications/src/main')
-rw-r--r--sonar-duplications/src/main/java/org/sonar/duplications/java/JavaStatementBuilder.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/sonar-duplications/src/main/java/org/sonar/duplications/java/JavaStatementBuilder.java b/sonar-duplications/src/main/java/org/sonar/duplications/java/JavaStatementBuilder.java
index 66917fa87d1..c382bfdbdec 100644
--- a/sonar-duplications/src/main/java/org/sonar/duplications/java/JavaStatementBuilder.java
+++ b/sonar-duplications/src/main/java/org/sonar/duplications/java/JavaStatementBuilder.java
@@ -43,6 +43,7 @@ public final class JavaStatementBuilder {
.statement(from("else"))
.statement(from("for"), bridge("(", ")"))
.statement(from("while"), bridge("(", ")"))
+ .statement(from("try"), bridge("(", ")"))
.statement(from("case"), to(";", "{", "}"), forgetLastToken())
.statement(from("default"), to(";", "{", "}"), forgetLastToken())
.statement(to(";", "{", "}"), forgetLastToken())