28479 Commits

Author SHA1 Message Date
Juan Martín Sotuyo Dodero
218222524f Update changelog, refs #5145 2024-08-23 14:36:12 -03:00
Clément Fournier
43112078a5 Fix issue #5145 - problem with inference of conditional exprs
Also finally fixes the bug that we swept under the rug in 24c1093b.
2024-08-23 18:23:43 +02:00
Charles Honton
8a39917fa2 added unit test 2024-08-22 13:54:17 -07:00
Charles Honton
3dd47a3b94 update AvoidSynchronizedAtMethodLevel message to mention ReentrantLock
see https://openjdk.org/jeps/8337395
2024-08-22 08:20:06 -07:00
Juan Martín Sotuyo Dodero
4033315c7d Properly handle all qualifiable expressions
- Up date the documentation to better show what is being flagged
2024-08-21 23:40:04 -03:00
Juan Martín Sotuyo Dodero
07f96e79ad Merge pull request #5171 from pmd/dependabot/maven/net.bytebuddy-byte-buddy-agent-1.14.19
Bump net.bytebuddy:byte-buddy-agent from 1.14.12 to 1.14.19
2024-08-19 01:47:04 -03:00
Juan Martín Sotuyo Dodero
90ebac893f Fix whitespace 2024-08-19 01:45:37 -03:00
dependabot[bot]
42468d769a Bump net.bytebuddy:byte-buddy-agent from 1.14.12 to 1.14.19
Bumps [net.bytebuddy:byte-buddy-agent](https://github.com/raphw/byte-buddy) from 1.14.12 to 1.14.19.
- [Release notes](https://github.com/raphw/byte-buddy/releases)
- [Changelog](https://github.com/raphw/byte-buddy/blob/master/release-notes.md)
- [Commits](https://github.com/raphw/byte-buddy/compare/byte-buddy-1.14.12...byte-buddy-1.14.19)

---
updated-dependencies:
- dependency-name: net.bytebuddy:byte-buddy-agent
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-19 03:50:15 +00:00
Juan Martín Sotuyo Dodero
15b006a52f Update changelog, refs #5153 2024-08-18 19:41:56 -03:00
Juan Martín Sotuyo Dodero
9ef927067e Fix tests regarding array accesses 2024-08-18 19:41:06 -03:00
Juan Martín Sotuyo Dodero
4352b53aec Add tests regarding array accesses 2024-08-18 19:40:51 -03:00
Juan Martín Sotuyo Dodero
33e7e71bfa Update changelog, refs #5152 2024-08-18 19:30:34 -03:00
Juan Martín Sotuyo Dodero
abcc20e655 Fix #5152 2024-08-18 19:29:48 -03:00
Juan Martín Sotuyo Dodero
176fae39d2 Add test for #5152 2024-08-18 19:29:39 -03:00
Juan Martín Sotuyo Dodero
0837be674e Update changelog, refs #5151 2024-08-18 19:24:46 -03:00
Juan Martín Sotuyo Dodero
792d91e062 Fix GuardLogStatementRule for field accesses 2024-08-18 19:23:25 -03:00
Juan Martín Sotuyo Dodero
ca34c3edd3 Add minimal failing case for #5151 2024-08-18 19:22:09 -03:00
dependabot[bot]
2192256b5a Bump jekyll and github-pages (#5165)
Bumps the all-gems group with 1 update in the /docs directory: [jekyll](https://github.com/jekyll/jekyll).


Updates `jekyll` from 3.9.5 to 3.10.0
- [Release notes](https://github.com/jekyll/jekyll/releases)
- [Changelog](https://github.com/jekyll/jekyll/blob/master/History.markdown)
- [Commits](https://github.com/jekyll/jekyll/compare/v3.9.5...v3.10.0)

Updates `github-pages` from 231 to 232
- [Release notes](https://github.com/github/pages-gem/releases)
- [Commits](https://github.com/github/pages-gem/compare/v231...v232)

---
updated-dependencies:
- dependency-name: jekyll
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: all-gems
- dependency-name: github-pages
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: all-gems
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-13 12:54:41 +02:00
dependabot[bot]
623de394ec Bump org.apache.maven.plugins:maven-site-plugin from 4.0.0-M13 to 4.0.0-M16 (#5149)
Bumps [org.apache.maven.plugins:maven-site-plugin](https://github.com/apache/maven-site-plugin) from 4.0.0-M13 to 4.0.0-M16.
- [Commits](https://github.com/apache/maven-site-plugin/compare/maven-site-plugin-4.0.0-M13...maven-site-plugin-4.0.0-M16)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-site-plugin
  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-08-13 12:53:15 +02:00
Andreas Dangel
b51be09795 [core] Cache moduleName to URLs in ClasspathClassLoader 2024-08-13 11:46:31 +01:00
Andreas Dangel
13b8556bf6 Fixup from review (#5112)
Co-authored-by: Clément Fournier <clement.fournier76@gmail.com>
2024-08-13 11:22:43 +01:00
Juan Martín Sotuyo Dodero
aa64ec3894 Merge pull request #5164 from pmd/dependabot/maven/org.apache.maven.plugins-maven-dependency-plugin-3.7.1
Bump org.apache.maven.plugins:maven-dependency-plugin from 3.6.1 to 3.7.1
2024-08-12 10:28:54 -03:00
dependabot[bot]
cc5fc196c5 Bump org.apache.maven.plugins:maven-dependency-plugin
Bumps [org.apache.maven.plugins:maven-dependency-plugin](https://github.com/apache/maven-dependency-plugin) from 3.6.1 to 3.7.1.
- [Release notes](https://github.com/apache/maven-dependency-plugin/releases)
- [Commits](https://github.com/apache/maven-dependency-plugin/compare/maven-dependency-plugin-3.6.1...maven-dependency-plugin-3.7.1)

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

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-12 03:37:24 +00:00
Juan Martín Sotuyo Dodero
3b105ca70b Merge pull request #5161 from pmd/dependabot/bundler/all-gems-d2126d6a76
Bump danger from 9.4.3 to 9.5.0 in the all-gems group across 1 directory
2024-08-05 06:21:42 -03:00
Juan Martín Sotuyo Dodero
913c44b3e4 Merge pull request #5160 from pmd/dependabot/maven/org.pcollections-pcollections-4.0.2
Bump org.pcollections:pcollections from 3.2.0 to 4.0.2
2024-08-05 06:20:41 -03:00
dependabot[bot]
c5de5d67a0 Bump danger from 9.4.3 to 9.5.0 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.4.3 to 9.5.0
- [Release notes](https://github.com/danger/danger/releases)
- [Changelog](https://github.com/danger/danger/blob/master/CHANGELOG.md)
- [Commits](https://github.com/danger/danger/commits)

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

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-05 03:57:58 +00:00
dependabot[bot]
49cfe186ae Bump org.pcollections:pcollections from 3.2.0 to 4.0.2
Bumps [org.pcollections:pcollections](https://github.com/hrldcpr/pcollections) from 3.2.0 to 4.0.2.
- [Changelog](https://github.com/hrldcpr/pcollections/blob/master/CHANGELOG.md)
- [Commits](https://github.com/hrldcpr/pcollections/compare/v3.2.0...v4.0.2)

---
updated-dependencies:
- dependency-name: org.pcollections:pcollections
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-08-05 03:18:42 +00:00
Andreas Dangel
21d499d5ef [doc] Release Notes for Java 23 Support (#5062)
Also add some @since tags to new API methods
2024-08-01 11:53:04 +02:00
Andreas Dangel
17a4a487a6 [java] CommentRequired - add test for markdown comments 2024-08-01 11:53:04 +02:00
Andreas Dangel
c53462b3b6 Improve RuleTst performance
Reuse the classloader for auxclasspath
instead of creating a new one for every
single rule test case.
2024-08-01 11:46:45 +02:00
Andreas Dangel
d171bcbdb3 [java] Default Imports for simple compilation unit
Import by default module java.base
and java.io.IO.*
2024-08-01 11:46:45 +02:00
Andreas Dangel
cbc475ede3 [java] Add ImplicitClassDeclaration
JEP 477: Implicitly Declared Classes and Instance Main Methods
(Third Preview)
2024-08-01 11:46:41 +02:00
Andreas Dangel
55d57acc63 [java] Remove String Template Preview feature for Java 23 2024-08-01 11:44:46 +02:00
Andreas Dangel
0823c88cba [java] Support primitive types in instanceof (Java 23 Preview)
Allow to use primitive types in patterns, instanceof, and
switch. This is a Java 23 Preview feature.
See JEP 455.
2024-08-01 11:44:45 +02:00
Andreas Dangel
47470b5d0c [java] Support module import declarations (JEP 476)
- new JModuleSymbol
- UnnecessaryImportRule also supports module imports
- module-info.class can be loaded by ClasspathClassLoader
- Support annotations on modules
- Verify that exported packages are loaded
2024-08-01 11:44:37 +02:00
Andreas Dangel
176e522721 [java] UnnecessaryImportRule: Support Markdown comments 2024-08-01 10:28:31 +02:00
Andreas Dangel
7a6662fcda [java] Support "Markdown documentation comments" (JEP 467) 2024-08-01 10:28:31 +02:00
Andreas Dangel
bb40b754a2 [java] Update impl for "Flexible Constructor Bodies" 2024-08-01 10:28:30 +02:00
Andreas Dangel
20750f9591 [java] Update implementation for "Implicitly Declared Classes...
... and Instance Main Methods" (JEP 477)

 - language feature is renamed
 - update symbol table resolver
2024-08-01 10:28:30 +02:00
Andreas Dangel
a7eab294b4 [java] Make UNNAMED_VARIABLES_AND_PATTERNS a regular language feature
This is now possible, since java 21 preview is gone.
2024-08-01 10:28:30 +02:00
Andreas Dangel
10681cd6a8 [java] Remove version 21-preview 2024-08-01 10:28:29 +02:00
Andreas Dangel
f13e886757 [java] Allow to build PMD with Java 23 2024-08-01 10:28:29 +02:00
Andreas Dangel
2a04d9858a [java] Bump asm from 9.6 to 9.7 2024-08-01 10:15:09 +02:00
Andreas Dangel
568314bb89 [java] Add new language version 23 and 23-preview 2024-08-01 10:15:09 +02:00
Juan Martín Sotuyo Dodero
10add3f0f7 Merge pull request #5148 from pmd/dependabot/maven/org.apache.commons-commons-text-1.12.0
Bump org.apache.commons:commons-text from 1.11.0 to 1.12.0
2024-07-29 09:08:18 -03:00
dependabot[bot]
65b6d5e796 Bump org.apache.commons:commons-text from 1.11.0 to 1.12.0
Bumps org.apache.commons:commons-text from 1.11.0 to 1.12.0.

---
updated-dependencies:
- dependency-name: org.apache.commons:commons-text
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-29 03:54:56 +00:00
Juan Martín Sotuyo Dodero
9ea10ecbe3 Merge pull request #5146 from adangel/issue-5139-apex-operationwithhighcostinloop
[apex] Fix parsing of triggers with declarations
2024-07-27 16:25:03 -03:00
Andreas Dangel
3735fd145b [apex] Fix parsing of triggers with declarations
Only the grandchildren of a trigger block were ending up in the tree,
but the direct children of triggerBlock were missing, e.g.
ForLoopStatement. This caused OperationWithHighCostInLoop to not
find the loop anymore in triggers.

This will probably fix other false negatives in triggers in
other rules as well.

Fixes #5139
2024-07-27 20:17:25 +02:00
dependabot[bot]
d2fbe14afa Bump org.codehaus.mojo:versions-maven-plugin from 2.16.2 to 2.17.1 (#5144)
Bumps [org.codehaus.mojo:versions-maven-plugin](https://github.com/mojohaus/versions) from 2.16.2 to 2.17.1.
- [Release notes](https://github.com/mojohaus/versions/releases)
- [Changelog](https://github.com/mojohaus/versions/blob/master/ReleaseNotes.md)
- [Commits](https://github.com/mojohaus/versions/compare/2.16.2...2.17.1)

---
updated-dependencies:
- dependency-name: org.codehaus.mojo:versions-maven-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-26 18:06:14 +02:00
dependabot[bot]
b7d9eaaa97 Bump org.apache.maven.plugins:maven-compiler-plugin from 3.12.1 to 3.13.0 (#5142)
Bumps [org.apache.maven.plugins:maven-compiler-plugin](https://github.com/apache/maven-compiler-plugin) from 3.12.1 to 3.13.0.
- [Release notes](https://github.com/apache/maven-compiler-plugin/releases)
- [Commits](https://github.com/apache/maven-compiler-plugin/compare/maven-compiler-plugin-3.12.1...maven-compiler-plugin-3.13.0)

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

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-26 17:46:08 +02:00