nbauma109 commented on PR #183: URL: https://github.com/apache/commons-bcel/pull/183#issuecomment-1500936601
> That's a lot of new APIs for one PR, are ALL of these new APIs actually used? If not, let's split this up since a PR where APIs are actually used from main, and another for the other APIs, otherwise this feels like we would be adding APIs for the sake of adding APIs. TY! I want to rewrite a cleaner code and avoid reflection hacks (i.e., setAccessible(true)), example here: https://github.com/nbauma109/jd-core/blob/0bcbf35f700f0cc48e1ef79456c37f9168f527ff/src/main/java/org/jd/core/v1/service/converter/classfiletojavasyntax/processor/ConvertClassFileProcessor.java#L375 I want to avoid recycling this boilerplate pattern for every single attribute: ```java MyAttribute attr = (MyAttribute) Stream.of(fieldOrMethod.getAttributes()).filter(MyAttribute.class::isInstance).findAny().orElse(null); ``` I have lots of them in that same class ConvertClassFileProcessor and in LocalVariableMaker. Other example for local variable type table: https://github.com/nbauma109/jd-core/blob/0bcbf35f700f0cc48e1ef79456c37f9168f527ff/src/main/java/org/jd/core/v1/service/converter/classfiletojavasyntax/util/ByteCodeWriter.java#L525 Also not sure what you mean by "are these new APIs actually used?", as far as I understand, they can't be used until they're published. I happen to create SNAPSHOTs of my forked BCEL for myself to check everything works as I want but that's it. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
