Skip to content

Commit

Permalink
Merge pull request #68 from Col-E/fix/asm-refactoring
Browse files Browse the repository at this point in the history
Improved support for Java 11+
  • Loading branch information
hazendaz authored Oct 30, 2022
2 parents 17e35c5 + 5b80a28 commit eb7d22c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
10 changes: 5 additions & 5 deletions main/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@
<url>https://github.com/jmockit/jmockit1/issues</url>
</issueManagement>
<distributionManagement>
<site>
<id>gh-pages-scm</id>
<name>gh-pages-scm</name>
<url>scm:git:ssh://[email protected]/hazendaz/jmockit1.git</url>
</site>
<site>
<id>gh-pages-scm</id>
<name>gh-pages-scm</name>
<url>scm:git:ssh://[email protected]/hazendaz/jmockit1.git</url>
</site>
</distributionManagement>

<properties>
Expand Down
7 changes: 4 additions & 3 deletions main/src/mockit/asm/constantPool/ConstantPoolGeneration.java
Original file line number Diff line number Diff line change
Expand Up @@ -390,9 +390,10 @@ public Item newConstItem(@Nonnull Object cst) {
if (cst instanceof MethodHandle) {
return newMethodHandleItem((MethodHandle) cst);
}
if(cst instanceof DynamicItem) {
DynamicItem dynamicItem = (DynamicItem) cst;
return createDynamicItem(dynamicItem.type, dynamicItem.name, dynamicItem.desc, dynamicItem.bsmIndex);

if (cst instanceof DynamicItem) {
DynamicItem dynamicItem = (DynamicItem) cst;
return createDynamicItem(dynamicItem.type, dynamicItem.name, dynamicItem.desc, dynamicItem.bsmIndex);
}
throw new IllegalArgumentException("value " + cst);
}
Expand Down

0 comments on commit eb7d22c

Please sign in to comment.