mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8323058: Revisit j.l.classfile.CodeBuilder API surface
Reviewed-by: briangoetz, psandoz
This commit is contained in:
parent
286cbf831c
commit
ae82405ff7
53 changed files with 725 additions and 876 deletions
File diff suppressed because it is too large
Load diff
|
@ -228,7 +228,7 @@
|
|||
* instruction invoking {@code println} could have been generated with {@link
|
||||
* java.lang.classfile.CodeBuilder#invokevirtual(java.lang.constant.ClassDesc,
|
||||
* java.lang.String, java.lang.constant.MethodTypeDesc) CodeBuilder.invokevirtual}, {@link
|
||||
* java.lang.classfile.CodeBuilder#invokeInstruction(java.lang.classfile.Opcode,
|
||||
* java.lang.classfile.CodeBuilder#invoke(java.lang.classfile.Opcode,
|
||||
* java.lang.constant.ClassDesc, java.lang.String, java.lang.constant.MethodTypeDesc,
|
||||
* boolean) CodeBuilder.invokeInstruction}, or {@link
|
||||
* java.lang.classfile.CodeBuilder#with(java.lang.classfile.ClassFileElement)
|
||||
|
|
|
@ -213,7 +213,7 @@ class PackageSnippets {
|
|||
if (e instanceof InvokeInstruction i
|
||||
&& i.owner().asInternalName().equals("Foo")
|
||||
&& i.opcode() == Opcode.INVOKESTATIC)
|
||||
b.invokeInstruction(i.opcode(), CD_Bar, i.name().stringValue(), i.typeSymbol(), i.isInterface());
|
||||
b.invoke(i.opcode(), CD_Bar, i.name().stringValue(), i.typeSymbol(), i.isInterface());
|
||||
else b.with(e);
|
||||
};
|
||||
// @end
|
||||
|
@ -327,7 +327,7 @@ class PackageSnippets {
|
|||
for (CodeElement e : xm) {
|
||||
if (e instanceof InvokeInstruction i && i.owner().asInternalName().equals("Foo")
|
||||
&& i.opcode() == Opcode.INVOKESTATIC)
|
||||
codeBuilder.invokeInstruction(i.opcode(), CD_Bar,
|
||||
codeBuilder.invoke(i.opcode(), CD_Bar,
|
||||
i.name().stringValue(), i.typeSymbol(), i.isInterface());
|
||||
else codeBuilder.with(e);
|
||||
}});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue