28592 Commits

Author SHA1 Message Date
Andreas Dangel
7bfa581511
Merge branch 'main' into pr-5296 2024-10-31 12:17:57 +01:00
Andreas Dangel
6ae7404941
[xml] XMLLexer - Update deprecation notice 2024-10-31 12:17:27 +01:00
Juan Martín Sotuyo Dodero
94095df872 Fix style issues 2024-10-29 17:21:24 -03:00
Juan Martín Sotuyo Dodero
7119424d96 Add license header 2024-10-29 16:56:30 -03:00
Juan Martín Sotuyo Dodero
69a92de52d Have pmd-xml Lexer in line with other antlr grammars
- The package is no longer antlr4, but ast, as is in all other modules
 - We keep a deprecated proxy for backwards compatibility
 - We annotate the generated classes as such to ignore them from
   coverage reports
2024-10-28 22:10:21 -03:00
Juan Martín Sotuyo Dodero
73dbc7a67f
Bump org.apache.maven.plugins:maven-assembly-plugin from 3.6.0 to 3.7.1 (#5290) 2024-10-28 14:06:52 -03:00
dependabot[bot]
c81cd1d520
Bump org.apache.maven.plugins:maven-assembly-plugin from 3.6.0 to 3.7.1
Bumps [org.apache.maven.plugins:maven-assembly-plugin](https://github.com/apache/maven-assembly-plugin) from 3.6.0 to 3.7.1.
- [Release notes](https://github.com/apache/maven-assembly-plugin/releases)
- [Commits](https://github.com/apache/maven-assembly-plugin/compare/maven-assembly-plugin-3.6.0...maven-assembly-plugin-3.7.1)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-assembly-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-10-28 03:31:36 +00:00
Juan Martín Sotuyo Dodero
4473aa6667
[ant] Formatter: avoid reflective access to determine console encoding (#5286) 2024-10-27 15:40:04 -03:00
Juan Martín Sotuyo Dodero
97d68e331c
Bump asm from 9.7 to 9.7.1 (#5288) 2024-10-27 12:38:42 -03:00
Andreas Dangel
d68d6c57ef
Bump asm from 9.7 to 9.7.1
This enables support for Java 24
Refs #5154
2024-10-27 15:53:00 +01:00
Andreas Dangel
9c098b2531
Bump pmd from 7.5.0 to 7.7.0 (#5285)
* Bump pmd from 7.5.0 to 7.7.0

* Bump build-tools from 27 to 28-SNAPSHOT

Needed to remove deprecation warnings
about old rule names
2024-10-27 15:20:28 +01:00
Andreas Dangel
3f697aff35
[ant] Formatter: avoid reflective access to determine console encoding
- for java 17+, there is public API to get the console encoding
  -> no problem
- for older java versions, try to use system property
  sun.jnu.encoding if it exists
- only then use the fall-backs with illegal reflective access
  to private fields/methods on java.io.Console
- Also avoid using reflection utils from apache commons, instead
  use reflection directly. The illegal access warnings are then
  properly reported against our class
  net.sourceforge.pmd.ant.Formatter.

Fixes #1860
2024-10-25 18:33:36 +02:00
Andreas Dangel
74ec6f45ee
[doc] Fix release notes for 7.7.0
Old rule name was actually DefaultLabelNotLastInSwitchStmt
2024-10-25 10:35:02 +02:00
Andreas Dangel
c179834288
[release] Prepare next development version [skip ci] 2024-10-25 09:28:54 +02:00
Andreas Dangel
7739f2b840
[release] prepare release pmd_releases/7.7.0 pmd_releases/7.7.0 2024-10-25 09:07:54 +02:00
Andreas Dangel
919e73f6b0
Prepare pmd release 7.7.0 2024-10-25 08:47:38 +02:00
Andreas Dangel
e2d59c0e64
Fix #5244: [java] UselessOperationOnImmutable: consider java.time.* types (#5279)
Merge pull request #5279 from adangel:issue-5244
2024-10-24 14:24:16 +02:00
Andreas Dangel
8f2d47dfb7
Fix #5270: [apex] AvoidNonRestrictiveQueries: Fix regex for detecting LIMIT clause (#5273)
Merge pull request #5273 from adangel:issue-5270
2024-10-24 14:22:25 +02:00
Andreas Dangel
e6097d6090
[java] Rename rule SwitchStmtsShouldHaveDefault to NonExhaustiveSwitch (#5267)
Merge pull request #5267 from adangel:issue-4286
2024-10-24 14:21:04 +02:00
Andreas Dangel
5e83246469
[doc] Update release notes (#5267) 2024-10-24 14:16:43 +02:00
Andreas Dangel
62c2858f70
Fix #5257: [java] NonCaseLabelInSwitch - support switch expressions (#5256)
Merge pull request #5256 from adangel:rename-nocaselabelswitch
2024-10-24 14:15:06 +02:00
Andreas Dangel
0d8878d58e
[java] Rename rule DefaultLabelNotLastInSwitch (#5255)
Merge pull request #5255 from adangel:rename-defaultlabelswitch
2024-10-24 14:10:16 +02:00
Andreas Dangel
4b23718aac
Fix #4813: [java] SwitchStmtsShouldHaveDefault false positive with pattern matching (#5252)
Merge pull request #5252 from adangel:issue-4813
2024-10-24 14:08:12 +02:00
Andreas Dangel
3a501a0f6b
Fix #5249 and #5250: [java] TooFewBranchesForSwitch ignore pattern matching and support switch expressions (#5251)
Merge pull request #5251 from adangel:issue-5249-5250
2024-10-24 14:06:03 +02:00
Andreas Dangel
36654ed52e
[java] UselessOperationOnImmutable: false positive on void results 2024-10-24 13:08:09 +02:00
Andreas Dangel
45b1217485
[java] TooFewBranchesForSwitch: don't report empty switch
Empty switch statements are already reported
by EmptyControlStatement
2024-10-24 12:51:42 +02:00
Andreas Dangel
662759755d
[java] SwitchStmtsShouldHaveDefault.xml: don't report empty switch
Empty switch statements are already reported
by EmptyControlStatement
2024-10-24 12:47:53 +02:00
Andreas Dangel
d9d6b57f2a
[java] TooFewBranchesForSwitch: report empty switch
This fixes a false negative
2024-10-24 12:38:45 +02:00
Andreas Dangel
6c35c73919
[java] SwitchStmtsShouldHaveDefault: use new PatternLabel attribute 2024-10-24 11:29:40 +02:00
Andreas Dangel
e37f82b62d
Merge branch 'main' into issue-4813 2024-10-24 11:24:17 +02:00
Andreas Dangel
6f5af6e585
[java] TooFewBranchesForSwitch: use new PatternLabel attribute 2024-10-24 11:22:47 +02:00
Andreas Dangel
66d879f707
Merge branch 'main' into issue-5249-5250 2024-10-24 11:20:39 +02:00
Andreas Dangel
93f6279ea7
Fix #3362: [java] ImplicitSwitchFallThrough should consider switch expressions (#5248) 2024-10-24 10:46:59 +02:00
Andreas Dangel
156f293ef3
Fix #5030: [java] SwitchDensity false positive with pattern matching (#5247) 2024-10-24 10:45:56 +02:00
Andreas Dangel
40ed4590be
[java] Improve UnitTestShouldUse{After,Before}Annotation rules to support JUnit5 and TestNG (#5245) 2024-10-24 10:43:48 +02:00
Andreas Dangel
7358289bbe
[cpp] Ignore literals and ignore identifiers capability to C++ CPD (#5040)
Merge pull request #5040 from jdupak:master
2024-10-24 10:18:39 +02:00
Andreas Dangel
a180258033
[doc] Update release notes (#5040) 2024-10-24 10:17:51 +02:00
Andreas Dangel
63675eaa18
[doc] Update release notes (#5279) 2024-10-22 21:03:22 +02:00
Andreas Dangel
49f2c15b83
[doc] Update release notes (#5273) 2024-10-22 21:01:42 +02:00
Andreas Dangel
15520211b5
Merge branch 'main' into issue-5270 2024-10-22 21:01:00 +02:00
Andreas Dangel
c4b8f18a36
[doc] Update release notes (#5252) 2024-10-22 20:58:37 +02:00
Andreas Dangel
c95817a75d
Merge branch 'main' into issue-4813 2024-10-22 20:55:38 +02:00
Andreas Dangel
09b0864eff
Apply suggestions from code review
Co-authored-by: Clément Fournier <clement.fournier@tu-dresden.de>
2024-10-22 20:50:10 +02:00
dependabot[bot]
1517a18956
Bump org.scala-lang:scala-reflect from 2.13.13 to 2.13.15 (#5281)
Bumps [org.scala-lang:scala-reflect](https://github.com/scala/scala) from 2.13.13 to 2.13.15.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](https://github.com/scala/scala/compare/v2.13.13...v2.13.15)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-reflect
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-22 20:23:50 +02:00
Juan Martín Sotuyo Dodero
97fe389dcc
Bump danger from 9.5.0 to 9.5.1 in the all-gems group across 1 directory (#5280) 2024-10-21 11:28:12 -03:00
dependabot[bot]
7df70ea7c1
Bump danger from 9.5.0 to 9.5.1 in the all-gems group across 1 directory
Bumps the all-gems group with 1 update in the / directory: [danger](https://github.com/danger/danger).


Updates `danger` from 9.5.0 to 9.5.1
- [Release notes](https://github.com/danger/danger/releases)
- [Changelog](https://github.com/danger/danger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/danger/danger/compare/v9.5.0...v9.5.1)

---
updated-dependencies:
- dependency-name: danger
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-gems
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-10-21 03:18:38 +00:00
Jakub Dupak
7ad4e0f0fc Add @jdupak as a contributor 2024-10-20 21:57:48 +02:00
Jakub Dupak
c47f5a6062 [cpd] Add ignore literals and identifiers capability to C++ 2024-10-20 21:57:48 +02:00
Andreas Dangel
6d55f6f053
[java] UselessOperationOnImmutable: consider java.time.* types
Fixes #5244
2024-10-18 17:42:44 +02:00
dependabot[bot]
b60b4d8a68
Bump com.google.protobuf:protobuf-java from 3.25.3 to 4.28.2 (#5234)
* Bump com.google.protobuf:protobuf-java from 3.25.3 to 4.28.2

Bumps [com.google.protobuf:protobuf-java](https://github.com/protocolbuffers/protobuf) from 3.25.3 to 4.28.2.
- [Release notes](https://github.com/protocolbuffers/protobuf/releases)
- [Changelog](https://github.com/protocolbuffers/protobuf/blob/main/protobuf_release.bzl)
- [Commits](https://github.com/protocolbuffers/protobuf/commits)

---
updated-dependencies:
- dependency-name: com.google.protobuf:protobuf-java
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* Cleanup comment about protobuf dependency

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Andreas Dangel <andreas.dangel@pmd-code.org>
2024-10-18 16:42:52 +02:00