git-svn-id: http://anonsvn.jboss.org/repos/javassist/trunk@456 30ef5769-5b8d-40dd-aea6-55b5d6557bb3tags/rel_3_17_1_ga
@@ -283,7 +283,8 @@ see javassist.Dump. | |||
<p>-version 3.9 | |||
<ul> | |||
<li>CtNewMethod.wrapped(..) implicitly appends a method like _added_m$0. | |||
<li>CtNewMethod.wrapped(..) and CtNewConstructor.wrapped(..) | |||
implicitly append a method like _added_m$0. | |||
This method now has a synthetic attribute. | |||
</ul> | |||
@@ -357,7 +357,7 @@ public class CtNewMethod { | |||
* Creates a wrapped method. The wrapped method receives parameters | |||
* in the form of an array of <code>Object</code>. | |||
* | |||
* <p>The body of the created method is a copy of the body of a method | |||
* <p>The body of the created method is a copy of the body of the method | |||
* specified by <code>body</code>. However, it is wrapped in | |||
* parameter-conversion code. | |||
* | |||
@@ -423,7 +423,7 @@ public class CtNewMethod { | |||
* <ul><pre>public class intVector extends java.util.Vector { | |||
* public void add(int p0) { | |||
* Object[] args = new Object[] { p0 }; | |||
* // begin of copied body | |||
* // begin of the copied body | |||
* super.addElement(args[0]); | |||
* Object result = null; | |||
* // end |
@@ -149,6 +149,7 @@ class CtNewWrappedMethod { | |||
map); | |||
int acc = body.getAccessFlags(); | |||
body.setAccessFlags(AccessFlag.setPrivate(acc)); | |||
body.addAttribute(new SyntheticAttribute(classfile.getConstPool())); | |||
// a stack map is copied. rebuilding it is not needed. | |||
classfile.addMethod(body); | |||
bodies.put(src, bodyname); |