Skip to content

Commit

Permalink
spotless apply
Browse files Browse the repository at this point in the history
  • Loading branch information
tonykwok1992 committed Mar 15, 2024
1 parent 350560a commit 479c284
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,8 @@ FieldSpec createBinaryDefinition(String binary) {
StringBuilder stringBuilderString = new StringBuilder().append("new StringBuilder()");
for (String s : argsArray) {
stringBuilderString.append(".append(\"");
stringBuilderString.append(s.replaceAll("\\$", "\\$\\$")); //escape $ which bytecode may contain
stringBuilderString.append(
s.replaceAll("\\$", "\\$\\$")); // escape $ which bytecode may contain
stringBuilderString.append("\")");
}
stringBuilderString.append(".toString()");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -980,9 +980,12 @@ public void testBuildFunctionLinkBinaryWithReferences() throws Exception {
assertEquals(methodSpec.toString(), (expected));
}


@Test
public void testBinaryWithUnlinkedLibraryLengthOver65534() throws Exception {
solidityFunctionWrapper.createBinaryDefinition("0x" + "a".repeat(40000) + "__$927c5a12e2f339676f56d42ec1c0537964$__" + "a".repeat(40000));
solidityFunctionWrapper.createBinaryDefinition(
"0x"
+ "a".repeat(40000)
+ "__$927c5a12e2f339676f56d42ec1c0537964$__"
+ "a".repeat(40000));
}
}

0 comments on commit 479c284

Please sign in to comment.