diff options
Diffstat (limited to 'src/core/lombok/bytecode/PreventNullAnalysisRemover.java')
-rw-r--r-- | src/core/lombok/bytecode/PreventNullAnalysisRemover.java | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/core/lombok/bytecode/PreventNullAnalysisRemover.java b/src/core/lombok/bytecode/PreventNullAnalysisRemover.java index cee6b24d..5c1bf124 100644 --- a/src/core/lombok/bytecode/PreventNullAnalysisRemover.java +++ b/src/core/lombok/bytecode/PreventNullAnalysisRemover.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010 The Project Lombok Authors. + * Copyright (C) 2010-2012 The Project Lombok Authors. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -29,10 +29,9 @@ import lombok.core.DiagnosticsReceiver; import lombok.core.PostCompilerTransformation; import org.mangosdk.spi.ProviderFor; -import org.objectweb.asm.ClassAdapter; import org.objectweb.asm.ClassReader; +import org.objectweb.asm.ClassVisitor; import org.objectweb.asm.ClassWriter; -import org.objectweb.asm.MethodAdapter; import org.objectweb.asm.MethodVisitor; import org.objectweb.asm.Opcodes; @@ -49,9 +48,9 @@ public class PreventNullAnalysisRemover implements PostCompilerTransformation { final AtomicBoolean changesMade = new AtomicBoolean(); - class PreventNullanalysisVisitor extends MethodAdapter { + class PreventNullanalysisVisitor extends MethodVisitor { PreventNullanalysisVisitor(MethodVisitor mv) { - super(mv); + super(Opcodes.ASM4, mv); } @Override public void visitMethodInsn(int opcode, String owner, String name, String desc) { @@ -68,7 +67,7 @@ public class PreventNullAnalysisRemover implements PostCompilerTransformation { } } - reader.accept(new ClassAdapter(writer) { + reader.accept(new ClassVisitor(Opcodes.ASM4, writer) { @Override public MethodVisitor visitMethod(int access, String name, String desc, String signature, String[] exceptions) { return new PreventNullanalysisVisitor(super.visitMethod(access, name, desc, signature, exceptions)); } |