Skip to content

Commit bcdd164

Browse files
committed
Merge tag 'javaparser-parent-3.25.4'
# Conflicts: # .github/workflows/maven_tests.yml # javaparser-core-generators/pom.xml # javaparser-core-generators/src/main/java/com/github/javaparser/generator/core/utils/CodeUtils.java # javaparser-core-metamodel-generator/pom.xml # javaparser-core-serialization/pom.xml # javaparser-core-testing-bdd/pom.xml # javaparser-core-testing/pom.xml # javaparser-core-testing/src/test/java/com/github/javaparser/ast/ParseResultTest.java # javaparser-core/pom.xml # javaparser-core/src/main/java/com/github/javaparser/UnicodeEscapeProcessingProvider.java # javaparser-core/src/main/java/com/github/javaparser/ast/Node.java # javaparser-core/src/main/java/com/github/javaparser/ast/body/FieldDeclaration.java # javaparser-core/src/main/java/com/github/javaparser/ast/type/VarType.java # javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/Difference.java # javaparser-core/src/main/java/com/github/javaparser/printer/lexicalpreservation/LexicalPreservingPrinter.java # javaparser-core/src/main/java/com/github/javaparser/resolution/declarations/ResolvedReferenceTypeDeclaration.java # javaparser-core/src/main/java/com/github/javaparser/resolution/logic/ConstructorResolutionLogic.java # javaparser-core/src/main/javacc/java.jj # javaparser-symbol-solver-core/pom.xml # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/JavaSymbolSolver.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/JavaParserFacade.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/JavaParserFactory.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/TypeExtractor.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/contexts/AbstractJavaParserContext.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/contexts/ContextHelper.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/contexts/LambdaExprContext.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/contexts/MethodCallExprContext.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/contexts/StatementContext.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javaparsermodel/declarations/JavaParserTypeParameter.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javassistmodel/JavassistAnnotationDeclaration.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javassistmodel/JavassistFactory.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/javassistmodel/JavassistTypeDeclarationAdapter.java # javaparser-symbol-solver-core/src/main/java/com/github/javaparser/symbolsolver/resolution/promotion/NumericConditionalExprHandler.java # javaparser-symbol-solver-testing/pom.xml # javaparser-symbol-solver-testing/src/test/java/com/github/javaparser/symbolsolver/resolution/DefaultPackageTest.java # pom.xml # readme.md
2 parents f25e309 + 67dcf3c commit bcdd164

File tree

147 files changed

+2197
-1653
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

147 files changed

+2197
-1653
lines changed

.github/workflows/create_github_release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: Checkout code
18-
uses: actions/[email protected].2
18+
uses: actions/[email protected].3
1919

2020
- name: Create Release
2121
id: create_release

.github/workflows/maven_tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
steps:
4747
## Checkout the current version of the code from the repo.
4848
- name: Checkout latest code
49-
uses: actions/[email protected].2
49+
uses: actions/[email protected].3
5050
with:
5151
fetch-depth: "0"
5252

@@ -103,7 +103,7 @@ jobs:
103103
runs-on: ubuntu-latest
104104
steps:
105105
- name: Checkout latest code
106-
uses: actions/[email protected].2
106+
uses: actions/[email protected].3
107107
with:
108108
fetch-depth: "0"
109109
- name: Set up JDK 17

.github/workflows/prepare_release_changelog.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717

1818
# Check out current repository
1919
- name: Fetch Sources
20-
uses: actions/[email protected].2
20+
uses: actions/[email protected].3
2121

2222
# Setup Java 11 environment for the next steps
2323
- name: Setup Java

.mvn/wrapper/maven-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,5 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17-
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.1/apache-maven-3.9.1-bin.zip
17+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.2/apache-maven-3.9.2-bin.zip
1818
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar

changelog.md

Lines changed: 97 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

2-
Next Release (Version 3.25.3-snapshot)
2+
Next Release (Version 3.25.5-snapshot)
33
--------------------------------------
4-
[issues resolved](https://github.com/javaparser/javaparser/milestone/199?closed=1)
4+
[issues resolved](https://github.com/javaparser/javaparser/milestone/201?closed=1)
55

66
### Added
77

@@ -15,6 +15,101 @@ Next Release (Version 3.25.3-snapshot)
1515

1616
### Security
1717

18+
19+
Version 3.25.4
20+
--------------
21+
[issues resolved](https://github.com/javaparser/javaparser/milestone/200?closed=1)
22+
23+
### Changed
24+
25+
* Nested 'if' statements should be simplified (PR [#4085](https://github.com/javaparser/javaparser/pull/4085) by [@jlerbsc](https://github.com/jlerbsc))
26+
* BDD tests: migarte to JBehave 5 (PR [#4028](https://github.com/javaparser/javaparser/pull/4028) by [@valfirst](https://github.com/valfirst))
27+
28+
### Fixed
29+
30+
* Fix: issue 4077 After building JavaParser (with tests) on MacOS multi… (PR [#4086](https://github.com/javaparser/javaparser/pull/4086) by [@jlerbsc](https://github.com/jlerbsc))
31+
* fix line separators of selected test files (PR [#4083](https://github.com/javaparser/javaparser/pull/4083) by [@abego](https://github.com/abego))
32+
* Fix: issue 3978 typesolver can't parse in parallel (PR [#4073](https://github.com/javaparser/javaparser/pull/4073) by [@jlerbsc](https://github.com/jlerbsc))
33+
* Fix #4056 isDeclaredInInterface() returns true for fields declared inside enumerations contained in an interface (PR [#4057](https://github.com/javaparser/javaparser/pull/4057) by [@Elewyth](https://github.com/Elewyth))
34+
* Fix: issue 4037 ArrayIndexOutOfBoundsException throws when method param is variadic (PR [#4046](https://github.com/javaparser/javaparser/pull/4046) by [@jlerbsc](https://github.com/jlerbsc))
35+
* Fix: issue 4016 Failed to parse variable with name 'sealed' or 'permits' (PR [#4039](https://github.com/javaparser/javaparser/pull/4039) by [@jlerbsc](https://github.com/jlerbsc))
36+
37+
### Developer Changes
38+
39+
* chore(deps): bump guava from 32.1.0-jre to 32.1.1-jre (PR [#4089](https://github.com/javaparser/javaparser/pull/4089) by [@dependabot[bot]](https://github.com/apps/dependabot))
40+
* chore(deps): bump guava from 32.0.0-jre to 32.1.0-jre (PR [#4087](https://github.com/javaparser/javaparser/pull/4087) by [@dependabot[bot]](https://github.com/apps/dependabot))
41+
* chore(deps): bump checkstyle from 10.12.0 to 10.12.1 (PR [#4084](https://github.com/javaparser/javaparser/pull/4084) by [@dependabot[bot]](https://github.com/apps/dependabot))
42+
* chore(deps): bump versions-maven-plugin from 2.15.0 to 2.16.0 (PR [#4055](https://github.com/javaparser/javaparser/pull/4055) by [@dependabot[bot]](https://github.com/apps/dependabot))
43+
* chore(deps): bump maven-release-plugin from 3.0.0 to 3.0.1 (PR [#4053](https://github.com/javaparser/javaparser/pull/4053) by [@dependabot[bot]](https://github.com/apps/dependabot))
44+
* chore(deps): bump guava from 31.1-jre to 32.0.0-jre (PR [#4042](https://github.com/javaparser/javaparser/pull/4042) by [@dependabot[bot]](https://github.com/apps/dependabot))
45+
* chore(deps): bump maven-dependency-plugin from 3.5.0 to 3.6.0 (PR [#4035](https://github.com/javaparser/javaparser/pull/4035) by [@dependabot[bot]](https://github.com/apps/dependabot))
46+
* chore(deps): bump maven-checkstyle-plugin from 3.2.2 to 3.3.0 (PR [#4033](https://github.com/javaparser/javaparser/pull/4033) by [@dependabot[bot]](https://github.com/apps/dependabot))
47+
* chore(deps): bump maven-scm-plugin from 2.0.0 to 2.0.1 (PR [#4031](https://github.com/javaparser/javaparser/pull/4031) by [@dependabot[bot]](https://github.com/apps/dependabot))
48+
* chore(deps): bump codecov/codecov-action from 3.1.3 to 3.1.4 (PR [#4030](https://github.com/javaparser/javaparser/pull/4030) by [@dependabot[bot]](https://github.com/apps/dependabot))
49+
* chore(deps): bump build-helper-maven-plugin from 3.3.0 to 3.4.0 (PR [#4026](https://github.com/javaparser/javaparser/pull/4026) by [@dependabot[bot]](https://github.com/apps/dependabot))
50+
* chore(deps): update dependency maven to v3.9.2 (PR [#4024](https://github.com/javaparser/javaparser/pull/4024) by [@renovate[bot]](https://github.com/apps/renovate))
51+
52+
### :heart: Contributors
53+
54+
Thank You to all contributors who worked on this release!
55+
56+
* [@valfirst](https://github.com/valfirst)
57+
* [@abego](https://github.com/abego)
58+
* [@Elewyth](https://github.com/Elewyth)
59+
* [@jlerbsc](https://github.com/jlerbsc)
60+
61+
62+
Version 3.25.3
63+
--------------
64+
[issues resolved](https://github.com/javaparser/javaparser/milestone/199?closed=1)
65+
66+
67+
### Added
68+
69+
* add Java 17 sealed/non-sealed classes (PR [#3997](https://github.com/javaparser/javaparser/pull/3997) by [@kris-scheibe](https://github.com/kris-scheibe))
70+
71+
### Changed
72+
73+
* Minor simplification of the Difference class (PR [#4008](https://github.com/javaparser/javaparser/pull/4008) by [@jlerbsc](https://github.com/jlerbsc))
74+
* Perf: Remove unnecessary methods and quickly return to the Range.cont… (PR [#3996](https://github.com/javaparser/javaparser/pull/3996) by [@jlerbsc](https://github.com/jlerbsc))
75+
76+
### Fixed
77+
78+
* Fix: issue 1843 Problems with hasAnnotation() and hasDirectlyAnnotati… (PR [#4015](https://github.com/javaparser/javaparser/pull/4015) by [@jlerbsc](https://github.com/jlerbsc))
79+
* Fix: Issue 3995 resolving a method call with a variadic argument of p… (PR [#3998](https://github.com/javaparser/javaparser/pull/3998) by [@jlerbsc](https://github.com/jlerbsc))
80+
* Fix: issue 3983 why FieldDeclaration in an interface calling isStatic… (PR [#3986](https://github.com/javaparser/javaparser/pull/3986) by [@jlerbsc](https://github.com/jlerbsc))
81+
82+
### Developer Changes
83+
84+
* chore(deps): bump checkstyle from 10.9.3 to 10.10.0 (PR [#4014](https://github.com/javaparser/javaparser/pull/4014) by [@dependabot[bot]](https://github.com/apps/dependabot))
85+
* chore(deps): update junit5 monorepo to v5.9.3 (PR [#4012](https://github.com/javaparser/javaparser/pull/4012) by [@renovate[bot]](https://github.com/apps/renovate))
86+
* chore(deps): bump jacoco-maven-plugin from 0.8.9 to 0.8.10 (PR [#4011](https://github.com/javaparser/javaparser/pull/4011) by [@dependabot[bot]](https://github.com/apps/dependabot))
87+
* chore(deps-dev): bump okhttp from 4.10.0 to 4.11.0 (PR [#4009](https://github.com/javaparser/javaparser/pull/4009) by [@dependabot[bot]](https://github.com/apps/dependabot))
88+
* chore(deps): bump codecov/codecov-action from 3.1.2 to 3.1.3 (PR [#4006](https://github.com/javaparser/javaparser/pull/4006) by [@dependabot[bot]](https://github.com/apps/dependabot))
89+
* chore(deps): bump maven-checkstyle-plugin from 3.2.1 to 3.2.2 (PR [#4005](https://github.com/javaparser/javaparser/pull/4005) by [@dependabot[bot]](https://github.com/apps/dependabot))
90+
* chore(deps): bump actions/checkout from 3.5.1 to 3.5.2 (PR [#3994](https://github.com/javaparser/javaparser/pull/3994) by [@dependabot[bot]](https://github.com/apps/dependabot))
91+
* chore(deps): bump actions/checkout from 3.5.0 to 3.5.1 (PR [#3992](https://github.com/javaparser/javaparser/pull/3992) by [@dependabot[bot]](https://github.com/apps/dependabot))
92+
* chore(deps): bump codecov/codecov-action from 3.1.1 to 3.1.2 (PR [#3988](https://github.com/javaparser/javaparser/pull/3988) by [@dependabot[bot]](https://github.com/apps/dependabot))
93+
* chore(deps): bump maven-deploy-plugin from 3.1.0 to 3.1.1 (PR [#3985](https://github.com/javaparser/javaparser/pull/3985) by [@dependabot[bot]](https://github.com/apps/dependabot))
94+
* chore(deps): bump jacoco-maven-plugin from 0.8.8 to 0.8.9 (PR [#3981](https://github.com/javaparser/javaparser/pull/3981) by [@dependabot[bot]](https://github.com/apps/dependabot))
95+
* chore(deps): bump checkstyle from 10.9.1 to 10.9.3 (PR [#3980](https://github.com/javaparser/javaparser/pull/3980) by [@dependabot[bot]](https://github.com/apps/dependabot))
96+
* chore(deps): bump maven-resources-plugin from 3.3.0 to 3.3.1 (PR [#3979](https://github.com/javaparser/javaparser/pull/3979) by [@dependabot[bot]](https://github.com/apps/dependabot))
97+
* chore(deps): bump maven-install-plugin from 3.1.0 to 3.1.1 (PR [#3975](https://github.com/javaparser/javaparser/pull/3975) by [@dependabot[bot]](https://github.com/apps/dependabot))
98+
* chore(deps): bump maven-release-plugin from 2.5.3 to 3.0.0 (PR [#3965](https://github.com/javaparser/javaparser/pull/3965) by [@dependabot[bot]](https://github.com/apps/dependabot))
99+
100+
### Uncategorised
101+
102+
* add test for showing interface field shall be static & final (PR [#3984](https://github.com/javaparser/javaparser/pull/3984) by [@XenoAmess](https://github.com/XenoAmess))
103+
104+
### :heart: Contributors
105+
106+
Thank You to all contributors who worked on this release!
107+
108+
* [@kris-scheibe](https://github.com/kris-scheibe)
109+
* [@jlerbsc](https://github.com/jlerbsc)
110+
* [@XenoAmess](https://github.com/XenoAmess)
111+
112+
18113
Version 3.25.2
19114
--------------
20115
[issues resolved](https://github.com/javaparser/javaparser/milestone/198?closed=1)

javaparser-core-generators/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<artifactId>jmlparser-parent</artifactId>
66
<groupId>io.github.jmltoolkit</groupId>
7-
<version>3.25.3-SNAPSHOT</version>
7+
<version>3.25.4</version>
88
</parent>
99
<modelVersion>4.0.0</modelVersion>
1010

javaparser-core-generators/src/main/java/com/github/javaparser/generator/core/utils/CodeUtils.java

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -25,33 +25,33 @@
2525

2626
public final class CodeUtils {
2727

28-
private CodeUtils() {
29-
// This constructor is used to hide the public one
30-
}
28+
private CodeUtils() {
29+
// This constructor is used to hide the public one
30+
}
3131

32-
/**
33-
* Cast the value if the current type doesn't match the required type.
34-
* <br>
35-
* Given the following example:
36-
* <code>
37-
* int withoutCast = 1;
38-
* double withCast = (double) 1;
39-
* </code>
40-
* The variable withoutCast doesn't need to be casted, since we have int as required type and int as value type.
41-
* While in the variable withCast we have double as required type and int as value type.
42-
*
43-
* @param value The value to be returned.
44-
* @param requiredType The expected type to be casted if needed.
45-
* @param valueType The type of the value to be returned.
46-
* @return The value casted if needed.
47-
*/
48-
public static String castValue(String value, Type requiredType, String valueType) {
49-
String requiredTypeName = requiredType.asString();
32+
/**
33+
* Cast the value if the current type doesn't match the required type.
34+
* <br>
35+
* Given the following example:
36+
* <code>
37+
* int withoutCast = 1;
38+
* double withCast = (double) 1;
39+
* </code>
40+
* The variable withoutCast doesn't need to be casted, since we have int as required type and int as value type.
41+
* While in the variable withCast we have double as required type and int as value type.
42+
*
43+
* @param value The value to be returned.
44+
* @param requiredType The expected type to be casted if needed.
45+
* @param valueType The type of the value to be returned.
46+
*
47+
* @return The value casted if needed.
48+
*/
49+
public static String castValue(String value, Type requiredType, String valueType) {
50+
String requiredTypeName = requiredType.asString();
5051

51-
if (requiredTypeName.equals(valueType))
52-
return value;
53-
else
54-
return String.format("(%s) %s", requiredTypeName, value);
55-
}
52+
if (requiredTypeName.equals(valueType))
53+
return value;
54+
return String.format("(%s) %s", requiredTypeName, value);
55+
}
5656

5757
}

javaparser-core-generators/src/main/java/com/github/javaparser/generator/core/visitor/NoCommentHashCodeVisitorGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ protected void generateVisitMethodBody(BaseNodeMetaModel node, MethodDeclaration
6262
if (propertyMetaModels.size() == 1) {
6363
builder.append("0");
6464
break;
65-
} else
66-
continue;
65+
}
66+
continue;
6767
}
6868
// Is this field another AST node? Visit it.
6969
if (field.getNodeReference().isPresent()) {

javaparser-core-metamodel-generator/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<artifactId>jmlparser-parent</artifactId>
66
<groupId>io.github.jmltoolkit</groupId>
7-
<version>3.25.3-SNAPSHOT</version>
7+
<version>3.25.4</version>
88
</parent>
99
<modelVersion>4.0.0</modelVersion>
1010

javaparser-core-serialization/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<parent>
44
<artifactId>jmlparser-parent</artifactId>
55
<groupId>io.github.jmltoolkit</groupId>
6-
<version>3.25.3-SNAPSHOT</version>
6+
<version>3.25.4</version>
77
</parent>
88
<modelVersion>4.0.0</modelVersion>
99

0 commit comments

Comments
 (0)