This is an automated email from the ASF dual-hosted git repository.

aherbert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-numbers.git

commit 8d702275555c2a6f0b1b349e7d8ca61e3eafe819
Author: aherbert <aherb...@apache.org>
AuthorDate: Tue Apr 25 13:56:05 2023 +0100

    Update PMD rules
    
    Remove deprecated ExcessiveClassLength and ExcessiveMethodLength. Enable
    NcssCount as a replacement. This can use similar PMD suppressions to
    ignore previously allowed violations of the deprecated rules.
---
 src/main/resources/pmd/pmd-ruleset.xml | 17 +++--------------
 1 file changed, 3 insertions(+), 14 deletions(-)

diff --git a/src/main/resources/pmd/pmd-ruleset.xml 
b/src/main/resources/pmd/pmd-ruleset.xml
index 94808ff8..f06d55ad 100644
--- a/src/main/resources/pmd/pmd-ruleset.xml
+++ b/src/main/resources/pmd/pmd-ruleset.xml
@@ -46,7 +46,6 @@
   <rule ref="category/java/design.xml">
     <exclude name="TooManyMethods" />
     <exclude name="LawOfDemeter" />
-    <exclude name="NcssCount" />
     <exclude name="LoosePackageCoupling" />
   </rule>
   <rule ref="category/java/documentation.xml">
@@ -138,16 +137,6 @@
                or @SimpleName='BigFraction']"/>
     </properties>
   </rule>
-  <rule ref="category/java/design.xml/ExcessiveClassLength">
-    <properties>
-      <property name="violationSuppressXPath"
-        
value="./ancestor-or-self::ClassOrInterfaceDeclaration[@SimpleName='Complex'
-               or @SimpleName='Fraction'
-               or @SimpleName='BigFraction'
-               or @SimpleName='BoostGamma'
-               or @SimpleName='BoostBeta']"/>
-    </properties>
-  </rule>
   <rule ref="category/java/design.xml/GodClass">
     <properties>
       <property name="violationSuppressXPath"
@@ -185,16 +174,16 @@
   </rule>
 
   <!-- Long methods are based on reference implementations. -->
-  <rule ref="category/java/design.xml/ExcessiveMethodLength">
+  <rule ref="category/java/design.xml/NcssCount">
     <properties>
       <property name="violationSuppressXPath"
         
value="./ancestor-or-self::ClassOrInterfaceDeclaration[@SimpleName='Complex'
-               or @SimpleName='BigFraction'
                or @SimpleName='Fraction'
                or @SimpleName='BoostErf'
                or @SimpleName='BoostGamma'
                or @SimpleName='BoostBeta'
-               or @SimpleName='SpecialMath']"/>
+               or @SimpleName='InvGamma1pm1'
+               or @SimpleName='BrentSolver']"/>
     </properties>
   </rule>
 

Reply via email to