enable some useful groovy inspections by default
authorpeter <peter@jetbrains.com>
Thu, 19 Jan 2012 17:09:26 +0000 (18:09 +0100)
committerpeter <peter@jetbrains.com>
Thu, 19 Jan 2012 17:09:26 +0000 (18:09 +0100)
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/bugs/GroovyConstructorNamedArgumentsInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/control/GroovyConditionalWithIdenticalBranchesInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/control/GroovyIfStatementWithIdenticalBranchesInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/exception/GroovyUnusedCatchParameterInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/threading/GroovyAccessToStaticFieldLockedOnInstanceInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/threading/GroovySynchronizationOnNonFinalFieldInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/threading/GroovySynchronizationOnVariableInitializedWithLiteralInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/threading/GroovyUnsynchronizedMethodOverridesSynchronizedMethodInspection.java
plugins/groovy/src/org/jetbrains/plugins/groovy/codeInspection/validity/GroovyDuplicateSwitchBranchInspection.java

index 45725393274ca97805bcbbd6118adb0f0f01a1a2..4950e316c5c82a7a2e5062b6bc4881553fbeb6f3 100644 (file)
@@ -46,6 +46,11 @@ import java.util.List;
 public class GroovyConstructorNamedArgumentsInspection extends BaseInspection {
 
   @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
+
+  @Override
   protected BaseInspectionVisitor buildVisitor() {
     return new MyVisitor();
   }
index 27ce86a987db4b11c78bee8f6df4e185369525c2..7d2c625cc39565a8c662baaa4f0b9c3ef6096f3d 100644 (file)
@@ -28,6 +28,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.GrCondit
 import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.GrExpression;
 
 public class GroovyConditionalWithIdenticalBranchesInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @NotNull
   public String getDisplayName() {
index b4149c88c3b5fac49a15fafbeb0d67430c6742fd..ecc473a23c4dcda286df7a60ce091a8083aeca40 100644 (file)
@@ -28,6 +28,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.GrIfStatement;
 import org.jetbrains.plugins.groovy.lang.psi.api.statements.GrStatement;
 
 public class GroovyIfStatementWithIdenticalBranchesInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @NotNull
   public String getDisplayName() {
index 8a2e10b158dbc0322cbc66433595e994f2881d4b..7c6165eaeeaba8dd304435dee13ac39cc3601c66 100644 (file)
@@ -25,6 +25,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.blocks.GrOpenBlock;
 import org.jetbrains.plugins.groovy.lang.psi.api.statements.params.GrParameter;
 
 public class GroovyUnusedCatchParameterInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @Nls
   @NotNull
index 2ece624af6dddda3a7a8fa71cd17f61791fb8adc..e39a99a645abfa10679fa3b265addef8d799ba24 100644 (file)
@@ -32,6 +32,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.typedef.members.GrMe
 
 public class GroovyAccessToStaticFieldLockedOnInstanceInspection
     extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @Nls
   @NotNull
index ba5942e83714f75e82de25839fc1a9c32a950e95..ca35d8b08d0cc948ac1528d3ac4c3a3f2885ad51 100644 (file)
@@ -29,6 +29,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.GrExpres
 import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.GrReferenceExpression;
 
 public class GroovySynchronizationOnNonFinalFieldInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @Nls
   @NotNull
index b3e1d04a21dee377a4ac439e17921fdfd5ce295d..4a5d8cba77673ab380207735cfee0ee00b4b23c2 100644 (file)
@@ -28,6 +28,10 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.GrRefere
 import org.jetbrains.plugins.groovy.lang.psi.api.statements.expressions.literals.GrLiteral;
 
 public class GroovySynchronizationOnVariableInitializedWithLiteralInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @Nls
   @NotNull
index 8ab22c682b0ab0538d81637751836f003aa1a029..ae311643e4c7e8626c064cead458468e14b8bb29 100644 (file)
@@ -26,6 +26,11 @@ import org.jetbrains.plugins.groovy.lang.psi.api.statements.typedef.members.GrMe
 
 public class GroovyUnsynchronizedMethodOverridesSynchronizedMethodInspection extends BaseInspection {
 
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
+
   @Nls
   @NotNull
   public String getGroupDisplayName() {
index 1115f85f17bc2582ecef0814074f48a6722f92e9..79fdc4ed3ee87bd1c166f4b5dbbcd964f4d9c52b 100644 (file)
@@ -31,6 +31,10 @@ import java.util.HashSet;
 import java.util.Set;
 
 public class GroovyDuplicateSwitchBranchInspection extends BaseInspection {
+  @Override
+  public boolean isEnabledByDefault() {
+    return true;
+  }
 
   @Nls
   @NotNull