Skip to content

Add missing Java 9 and Java 11 class file attributes.#33

Merged
garydgregory merged 5 commits intoapache:masterfrom
markro49:java9
Aug 27, 2019
Merged

Add missing Java 9 and Java 11 class file attributes.#33
garydgregory merged 5 commits intoapache:masterfrom
markro49:java9

Conversation

@markro49
Copy link
Contributor

Add support for several class file attributes added for Java 9 and Java 11. At some point, may wish to add additional getters and setters. Current level of support is enough to read, write and display all fields of each attribute.

Also did some work to make the various attribute toString() methods produce similarly formatted output.

This pull request is in response to https://issues.apache.org/jira/browse/BCEL-325. In addition to adding support for the missing attributes, it fixes a problem building and running on Java 9.

@markro49
Copy link
Contributor Author

working on java 11 failures

/**
* @since 6.0
*/
void visitMethodParameter(MethodParameter obj);
Copy link
Member

@garydgregory garydgregory Aug 26, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @markro49,
New methods in interfaces must be added as Java 8 default methods in order for us to maintain binary compatibility. Also the @since should be for 6.4.0, not 6.0.
Gary

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand the compatibility requirement, but I am unsure of what it means to make them a Java 8 default method.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Supply default visitMethodParameter implementation for Visitor interface.
@garydgregory garydgregory merged commit 8dc6bba into apache:master Aug 27, 2019
asfgit pushed a commit that referenced this pull request Aug 27, 2019
@markro49 markro49 deleted the java9 branch March 4, 2020 18:48
Raygama referenced this pull request in Raygama/bcel-demo Aug 30, 2025
[BCEL-326] Add missing Java 9 and Java 11 class file attributes.  #33.  Use @SInCE 6.4.0 instead of 6.4.
Raygama referenced this pull request in Raygama/bcel-demo Aug 30, 2025
"Add missing Java 9 and Java 11 class file attributes. (#33)  * Add missing Java 9 and Java 11 class file attributes.

 * update for newer attributes

 * add missing visitor needed by java 11

 * Correct version number comments.
 Supply default visitMethodParameter implementation for Visitor interface."
Raygama referenced this pull request in Raygama/bcel-demo Sep 18, 2025
[BCEL-326] Add missing Java 9 and Java 11 class file attributes. #33.  Use @SInCE 6.4.0 instead of 6.4.
Raygama referenced this pull request in Raygama/bcel-demo Sep 18, 2025
"Add missing Java 9 and Java 11 class file attributes. (#33)  * Add missing Java 9 and Java 11 class file attributes.

 * update for newer attributes

 * add missing visitor needed by java 11

 * Correct version number comments.
 Supply default visitMethodParameter implementation for Visitor interface."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants