1 Apache Commons BCEL 2 Version 6.3-SNAPSHOT 3 RELEASE NOTES 4 5 6INTRODUCTION: 7 8The Apache Commons BCEL team is pleased to announce the release of 9Apache Commons BCEL 6.3-SNAPSHOT! 10 11The Byte Code Engineering Library (BCEL) is intended to give users a convenient 12way to analyze, create, and manipulate compiled .class files. Classes are 13represented by objects containing all the symbolic information of the given 14class: methods, fields and byte code instructions. 15 16? 17 18NEW FEATURES: 19============= 20 21o Added org.apache.bcel.classfile.Visitor.visitConstantDynamic(ConstantDynamic) Thanks to Mark Thomas. 22o Added org.apache.bcel.classfile.ConstantDynamic Thanks to Mark Thomas. 23o Added fields in org.apache.bcel.Const for Java 9, 10, and 11. Thanks to Mark Thomas. 24o Added fields in org.apache.bcel.Const for Java 12 and 13 based on Java Early Access releases. Thanks to Mark Thomas. 25 26FIXED BUGS: 27=========== 28 29o BCEL-304: ClassPath.getClassFile() and friends do not work with JDK 9 and higher (PR #22.) Thanks to Gary Gregory, Ed Pavlak. 30o BCEL-305: ClassPath.getClassFile() and friends do not work with JRE 9 and higher Thanks to Gary Gregory. 31 32CHANGES: 33======== 34 35o Initial support for Java 11 Thanks to Mark Thomas, Gary Gregory. 36o Update Java requirement from Java 7 to Java 8. Thanks to Gary Gregory. 37 38 39 40Have fun! 41-Apache Commons BCEL team 42 43Feedback 44-------- 45 46Open source works best when you give feedback: 47 48 http://commons.apache.org/bcel 49 50Please direct all bug reports to JIRA: 51 52 https://issues.apache.org/jira/browse/BCEL 53 54Or subscribe to the commons-user mailing list 55 56The Apache Commons Team 57 58----------------------------------------------------------------------------- 59 60 Apache Commons BCEL 61 Version 6.2 62 RELEASE NOTES 63 64 65INTRODUCTION: 66 67The Apache Commons BCEL team is pleased to announce the release of 68Apache Commons BCEL 6.2! 69 70The Byte Code Engineering Library (BCEL) is intended to give users a convenient 71way to analyze, create, and manipulate compiled .class files. Classes are 72represented by objects containing all the symbolic information of the given 73class: methods, fields and byte code instructions. 74 75Experimental Java 9 Support 76 77FIXED BUGS: 78=========== 79 80o BCEL-294: Incorrect comment in StackMap.java Thanks to Mark Roberts. 81o BCEL-296: Incorrect comment in several classes. Thanks to Mark Roberts. 82o BCEL-295: Fix local variable live range length; add test case. Thanks to Mark Roberts. 83o BCEL-300: org.apache.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19. 84o BCEL-301: org.apache.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 20. 85 86 87Have fun! 88-Apache Commons BCEL team 89 90Feedback 91-------- 92 93Open source works best when you give feedback: 94 95 http://commons.apache.org/bcel 96 97Please direct all bug reports to JIRA: 98 99 https://issues.apache.org/jira/browse/BCEL 100 101Or subscribe to the commons-user mailing list 102 103The Apache Commons Team 104 105----------------------------------------------------------------------------- 106 107 Apache Commons BCEL 108 Version 6.1 109 RELEASE NOTES 110 111 112INTRODUCTION: 113 114The Apache Commons BCEL team is pleased to announce the release of 115Apache Commons BCEL 6.1! 116 117The Byte Code Engineering Library (BCEL) is intended to give users a convenient 118way to analyze, create, and manipulate compiled .class files. Classes are 119represented by objects containing all the symbolic information of the given 120class: methods, fields and byte code instructions. 121 122Apache Commons BCEL 6.1 is a bugfix and feature release supporting bringing 123experimental support for Java 9. 124 125It requires Java 7 or higher to run. 126 127 128COMPATIBILITY with 6.1 129====================== 130 131Binary compatible - Yes 132 133Source compatible - Yes, sort of; 134 - The org.apache.bcel.classfile.Visitor interface has been enhanced with 135 additional methods. If you implemented it directly instead of extending 136 the EmptyVisitor class you'll have to implement the new methods. 137 - The org.apache.bcel.generic.Visitor interface has been enhanced with an 138 additional method. If you implemented it directly instead of extending 139 the EmptyVisitor class you'll have to implement the new methods. 140 141Semantic compatible - Yes 142 143For full information about API changes please see the extended Clirr report: 144 145 146http://commons.apache.org/bcel/clirr-report.html 147 148 149COMPATIBILITY with Java 9 150========================= 151 152The MANIFEST.MF now contains an additional entry: 153 154 Automatic-Module-Name: org.apache.bcel 155 156This should make it possible to use Commons BCEL 6.1 as a module in the Java 9 157module system. For more information see the corresponding issue and the 158referenced mailing list discussions: 159 160https://issues.apache.org/jira/browse/BCEL-293 161 162The build currently on Java 9 fails with test failures related to Locales. We 163are still working on this. For more information see: 164 165https://issues.apache.org/jira/browse/BCEL-275 166 167 168NEW FEATURES: 169============= 170 171o BCEL-293: Add Automatic-Module-Name MANIFEST entry for Java 9 compatibility. 172o BCEL-292: Add minimal Java 9 support. 173 174FIXED BUGS: 175=========== 176 177o BCEL-286: Utility.signatureToString fails if a method has multiple type 178 arguments. Thanks to Mark Roberts. 179o BCEL-287: IINC does not handle -128 properly. Thanks to Mark Roberts. 180o BCEL-283: Support for StackMap should be different from StackMapTable. 181 Thanks to Mark Roberts. 182o BCEL-289: Crash when parsing constructor of inner classes with parameters 183 annotated. 184o BCEL-276: LocalVariableTypeTable is not updated. 185 Thanks to Sam Yoon, Mark Roberts. 186o BCEL-277: Resolving the String representation of a constant throws 187 NoSuchElementException in case of CONSTANT_NameAndType constant. 188 Thanks to Sam Yoon. 189 190 191Have fun! 192-Apache Commons BCEL team 193 194----------------------------------------------------------------------------- 195 196 Release Notes for 6.0 197 198 199INTRODUCTION: 200 201The Apache Commons BCEL team is pleased to announce the release of 202Apache Commons BCEL 6.0! 203 204The Byte Code Engineering Library (BCEL) is intended to give users a convenient 205way to analyze, create, and manipulate compiled .class files. Classes are 206represented by objects containing all the symbolic information of the given 207class: methods, fields and byte code instructions. 208 209Apache Commons BCEL 6.0 is a major release supporting the new features 210introduced in Java 6, 7 and 8. 211 212It requires Java 7 or higher to run. 213 214 215COMPATIBILITY with 5.2 216====================== 217 218Binary compatible - not strictly compatible 219- The constant interface org.apache.bcel.Constants has been deprecated. Classes 220 which implemented this interface in 5.2 now use the constants defined in the 221 org.apache.bcel.Const class. 222- The constant interface org.apache.bcel.generic.InstructionConstants has been 223 deprecated. Classes which implemented this interface in 5.2 now use the 224 constants defined in the org.apache.bcel.generic.InstructionConsts class. 225- Return type of method 'public java.lang.Object getElementAt(int)' in 226 org.apache.bcel.verifier.VerifierFactoryListModel has been changed to 227 java.lang.String. 228- The BCEL classes do no longer implement java.io.Serializable. 229 230Source compatible - Yes, sort of; 231 - The org.apache.bcel.classfile.Visitor interface has been enhanced with 232 additional methods. If you implemented it directly instead of extending 233 the EmptyVisitor class you'll have to implement the new methods. 234 - The org.apache.bcel.generic.Visitor interface has been enhanced with an 235 additional method. If you implemented it directly instead of extending 236 the EmptyVisitor class you'll have to implement the new methods. 237 238Semantic compatible - Yes, except: 239 - BCEL 6.0 handles new attributes such as code annotations that could only 240 be processed by implementing a custom AttributeReader in the previous 241 versions. Code relying on this behavior will have to be adjusted since 242 the AttributeReader will no longer be called in these cases. 243 244For full information about API changes please see the extended Clirr report: 245 246 247http://commons.apache.org/bcel/clirr-report.html 248 249NEW FEATURES: 250============= 251 252o BCEL-272: Add constants for Java 9 class file version 53. 253 254FIXED BUGS: 255=========== 256 257o BCEL-237: non-empty final arrays should be private as they are mutable. 258o BCEL-243: Type.getType() needs to understand TypeVariableSignature(s). 259o BCEL-271: FCONST pattern does not include FCONST_2. 260o BCEL-264: Add missing Node.accept() implementations (ConstantMethodHandle, 261 ConstantMethodType, ParameterAnnotationEntry). 262o BCEL-221: BCELifier is not working for Java8Example (incomplete). 263o BCEL-195: Addition of hashCode() to generic/Instruction.java breaks Targeters. 264 Never make distinct BranchInstructions compare equal. 265o BCEL-261: Select constructor allows partially constructed instance to escape. 266 Re-ordered code to delay the escape. 267o BCEL-259: Minor doc error in BranchInstruction.java. 268o BCEL-260: ClassDumper example duplicates field attribute types. 269o BCEL-258: No tests to check the output of dump methods. 270o BCEL-257: INVOKESPECIAL, INVOKESTATIC, INVOKEVIRTUAL need to define dump() 271 methods. 272o BCEL-254: Two more methods that would be nice to be public. 273o BCEL-245: Type class includes constants that reference subclasses. 274o BCEL-253: Pass 3b verifier is too strict. 275o BCEL-248: StackMapTable[Entry] should be removed and improvements merged into 276 StackMap[Entry]. 277o BCEL-202: StackMap[Table]Entry.copy() needs to be deep; Improved support for 278 StackMaps. 279o BCEL-251: Pass3aVerifier visitANEWARRAY() does not allow 255 array dimensions. 280o BCEL-249: Check for max Short seems wrong. 281o BCEL-208: Need to check for an empty InstructionList. 282o BCEL-217: long type instructions are not searched by InstructionFinder using 283 regular expression. 284o BCEL-239: Interfaces should not be used to define constants. 285o BCEL-234: Code must not swallow Throwable. 286o BCEL-209: Bug fixes and improvements to InvokeDynamic and BootStrapMethods 287 implementation. Thanks to Mark Roberts. 288o BCEL-187: Verification error when an invoke references a method defined in 289 superclass. Thanks to Jérôme Leroux. 290o BCEL-218: Remove ObjectType cache. Thanks to chas. 291o BCEL-184: The verifier now checks if methods with a void return type attempt 292 to return an object. Thanks to Jérôme Leroux. 293o BCEL-207: MethodGen.removeLocalVariable now properly unreference the removed 294 variable from the targetters of the instruction handlers delimiting 295 the scope of the variable. Thanks to Mark Roberts. 296o BCEL-197: Utility.signatureToString() no longer throws a ClassFormatException 297 on TypeVariables found in generic signatures. Thanks to Mark Roberts. 298o BCEL-194: Removed the 'index' variable from the LocalVariableGen's hash code. Thanks to Mark Roberts. 299o BCEL-193: The verifier should not check for run time compatibility of objects 300 assigned to arrays. Thanks to Jérôme Leroux. 301o BCEL-188: Correct verification of the return value of a method. Thanks to Jérôme Leroux. 302o BCEL-186: Performance degradation with the UTF8 cache. getInstance no longer 303 uses cache. 304o BCEL-181: org.apache.bcel.util.ClassLoaderRepository.loadClass(String) leaks 305 input streams. 306o BCEL-28: Mistake in "Peephole optimizer" example 307 at http://commons.apache.org/bcel/manual.html 308o BCEL-74: BCEL cannot be used as java.system.class.loader. 309o BCEL-77: XSLT transforms broken in Turkish Locale. 310o BCEL-79: java.lang.ClassFormatError: LVTT entry for 'local' in class file 311 org/shiftone/jrat/test/dummy/CrashTestDummy does not match any LVT 312 entry 313o BCEL-81: ClassParser.parse() throws NullPointerException if class does not 314 exist and ClassParser(String) constructor is used. 315o BCEL-85: ArrayOutOfBoundsException in InstructionFinder. 316o BCEL-87: Website: Incorrect URL for source; version 5.2 is not in the bug 317 page 318o BCEL-88: bcelified method doesn't pass verification. 319o BCEL-89: return type not verified by JustIce. 320o BCEL-94: @since tag incorrect for Annotation classes in BCEL trunk. 321o BCEL-95: InstructionFactory missing % operator for Float, Double. 322o BCEL-96: Fields in Annotations and AnnotationEntry are inaccessible to 323 subclasses 324o BCEL-97: Add support for getResources to ClassPath. 325o BCEL-98: Two source files in repository are empty. 326o BCEL-99: Maven POM file calls in apache regex but code does not use it. 327o BCEL-100: ClassParser throws unintelligible Exception. 328o BCEL-101: verifier raises an AssertionViolatedException when done against 329 Java 5 files with generics/annotations. 330o BCEL-102: Verifier fails in pass 2 with "Number of LocalVariableTable 331 attributes of Code attribute" on static methods. 332o BCEL-107: ParameterAnnotationEntries are read not dumped. 333o BCEL-108: RuntimeVisible Annotations duplicated. 334o BCEL-112: ARRAYLENGTH incorrectly not StackConsumer. 335o BCEL-114: Error in method search() defined in 336 org.apache.bcel.util.InstructionFinder 337o BCEL-115: Deleting all instructions of a list shows wrong behaviour. 338o BCEL-120: Make BCEL JAR OSGi compatible. 339o BCEL-122: ArrayIndexOutOfBoundsException thrown from TABLESWITCH.initFromFile. 340o BCEL-124: tableswitch/lookupswitch invalid alignment of 4-byte operands. 341o BCEL-125: Incorrect size calculation in InstructionFinder. 342o BCEL-130: Class files containing "ParameterAnnotations" are dumped 343 incorrectly. 344o BCEL-131: Class files containing "StackMapTable" attributes (on method code) 345 are dumped incorrectly. 346o BCEL-132: org.apache.bcel.classfile.ClassParser: NullPointerException caused 347 by fileopen failed. 348o BCEL-133: org.apache.bcel.classfile.ClassParser: NullPointerException caused 349 by invalid filename. 350o BCEL-134: ExecutionVisitor doesn't support Class constant type for LDC and 351 LDC_W. 352o BCEL-135: BCELifier issue: BCELFactory fails to handle float and long 353 constants. 354o BCEL-137: "Invalid method signature: TT;" when using MethodGen for a method 355 having a generic parameter. 356o BCEL-138: FieldInstruction.getFieldSize() doesn't decode Type.getTypeSize() 357 output. 358o BCEL-140: org.apache.bcel.generic.Instruction.equals(Object) does not follow 359 Object.equals(Object) rules. 360o BCEL-141: Select instructions should implement StackConsumer instead of 361 StackProducer. 362o BCEL-143: Fix CPL License issues with EnclosingMethod.java and 363 LocalVariableTypeTable.java. 364o BCEL-145: Type.getReturnTypeSize() doesn't decode Type.getTypeSize() output. 365o BCEL-146: SyntheticRepository.loadClass() fails to close the inputStream. 366o BCEL-148: BCELifier produces incorrect code for methods containing loads of 367 class literals from constant pool. 368o BCEL-151: Code attribute size not updated. 369o BCEL-152: Incorrect link for Jasmin assembler language. 370o BCEL-153: Examples not present in source or binary downloads. 371o BCEL-154: ClassParser.parse() generates NPE if it cannot open the file. 372o BCEL-155: InstConstraintVisitor does not handle class constants. 373o BCEL-156: Pass3bVerifier crashes on empty methods. 374o BCEL-159: LocalVariableGen.getLocalVariable() computes incorrect length. 375o BCEL-164: Method does not have a method to access parameter annotations. 376o BCEL-167: ClassPath.getResource does not correctly perform URL escaping. 377o BCEL-173: ClassParser fails to parse JDK classes in Java 8: 378 ClassFormatException: Invalid byte tag in constant pool. 379o BCEL-174: Verification of interfaces with default methods fails with Java 8. 380o BCEL-177: When reading the number of parameters in a MethodParameters 381 structure only read a single byte as per the JVM specification. 382 383CHANGES: 384======== 385 386o BCEL-262: InvokeInstruction.getClassName(ConstantPoolGen) should not throw 387 an exception when it detects an array. Thanks to Mark Roberts. 388o BCEL-230: Document the Java platform requirement clearly and early. 389o BCEL-211: Some additional clone methods should be public. 390o BCEL-127: Document that Instruction Factory returns singleton instances. 391o BCEL-198: better support for clone/copy methods. 392o BCEL-201: modify several toString methods to make output similar to "javap". 393o BCEL-205: add javadoc comments to LineNumber.java and LineNumberTable.java. 394o BCEL-212: Inconsistent toString() results. 395o BCEL-244: Update Java requirement from 5 to 7. 396o BCEL-219: Make org.apache.bcel.classfile.ConstantPool.ConstantPool(DataInput) 397 public. Thanks to Maxim Degtyarev. 398o BCEL-76: Add parent type processing for ClassPath class. 399o BCEL-83: Add support for getResource and getResourceAsStream to ClassPath. 400o BCEL-92: Properly parse StackMapTable attributes in Java 6 classfiles. 401o BCEL-104: Javadoc overhaul. 402o BCEL-119: BCEL is unnecessarily slow. 403o BCEL-157: Add support for INVOKEDYNAMIC and MethodHandles. 404o BCEL-160: Why using unstable sort at MethodGen.getLocalVariables() ? 405o BCEL-163: Incorporate patch file from Findbugs. 406o BCEL-175: Implement the MethodParameters attribute. 407 408REMOVED: 409======== 410o BCEL-242: Remove Serializable. 411o BCEL-110: Problem with JAXB if the bcel classloader is used; remove the broken 412 ClassLoader class. 413 414 415Have fun! 416-Apache Commons BCEL team 417 418Feedback 419-------- 420 421Open source works best when you give feedback: 422 423 http://commons.apache.org/bcel 424 425Please direct all bug reports to JIRA: 426 427 https://issues.apache.org/jira/browse/BCEL 428 429Or subscribe to the commons-user mailing list 430 431The Apache Commons Team 432