summaryrefslogtreecommitdiffstats
path: root/src/main/javassist/CtConstructor.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/javassist/CtConstructor.java')
-rw-r--r--src/main/javassist/CtConstructor.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/javassist/CtConstructor.java b/src/main/javassist/CtConstructor.java
index 403ce95d..25113889 100644
--- a/src/main/javassist/CtConstructor.java
+++ b/src/main/javassist/CtConstructor.java
@@ -289,7 +289,10 @@ public final class CtConstructor extends CtBehavior {
*/
public void setBody(String src) throws CannotCompileException {
if (src == null)
- src = "super();";
+ if (isClassInitializer())
+ src = ";";
+ else
+ src = "super();";
super.setBody(src);
}