Buggy code:
public class BcelTypeMunger extends ConcreteTypeMunger { public BcelTypeMunger ( ResolvedTypeMunger munger , ResolvedType aspectType ) { } public String toString ( ) { } public boolean munge ( BcelClassWeaver weaver ) { } private String getShortname ( String path ) { } private boolean mungeNewAnnotationOnType ( BcelClassWeaver weaver , AnnotationOnTypeMunger munger ) { } private boolean mungeNewParent ( BcelClassWeaver weaver , NewParentTypeMunger munger ) { } private boolean enforceDecpRule1_abstractMethodsImplemented ( BcelClassWeaver weaver , ISourceLocation mungerLoc , LazyClassGen newParentTarget , ResolvedType newParent ) { } private boolean enforceDecpRule2_cantExtendFinalClass ( BcelClassWeaver weaver , ISourceLocation mungerLoc , LazyClassGen newParentTarget , ResolvedType newParent ) { } private boolean enforceDecpRule3_visibilityChanges ( BcelClassWeaver weaver , ResolvedType newParent , ResolvedMember superMethod , LazyMethodGen subMethod ) { } private boolean enforceDecpRule4_compatibleReturnTypes ( BcelClassWeaver weaver , ResolvedMember superMethod , LazyMethodGen subMethod ) { } private boolean enforceDecpRule5_cantChangeFromStaticToNonstatic ( BcelClassWeaver weaver , ISourceLocation mungerLoc , ResolvedMember superMethod , LazyMethodGen subMethod ) { } public void error ( BcelClassWeaver weaver , String text , ISourceLocation primaryLoc , ISourceLocation [ ] extraLocs ) { } private LazyMethodGen findMatchingMethod ( LazyClassGen newParentTarget , ResolvedMember m ) { } public boolean attemptToModifySuperCalls ( BcelClassWeaver weaver , LazyClassGen newParentTarget , ResolvedType newParent ) { String currentParent = newParentTarget . getSuperClassname ( ) ; List mgs = newParentTarget . getMethodGens ( ) ; for ( Iterator iter = mgs . iterator ( ) ; iter . hasNext ( ) ; ) { LazyMethodGen aMethod = ( ( LazyMethodGen ) ( iter . next ( ) ) ) ; if ( aMethod . getName ( ) . equals ( "<init>" ) ) { InstructionList insList = aMethod . getBody ( ) ; InstructionHandle handle = insList . getStart ( ) ; while ( handle != null ) { if ( ( handle . getInstruction ( ) ) instanceof INVOKESPECIAL ) { ConstantPoolGen cpg = newParentTarget . getConstantPoolGen ( ) ; INVOKESPECIAL invokeSpecial = ( ( INVOKESPECIAL ) ( handle . getInstruction ( ) ) ) ; if ( ( invokeSpecial . getClassName ( cpg ) . equals ( currentParent ) ) && ( invokeSpecial . getMethodName ( cpg ) . equals ( "<init>" ) ) ) { ResolvedMember newCtor = getConstructorWithSignature ( newParent , invokeSpecial . getSignature ( cpg ) ) ; if ( newCtor == null ) { boolean satisfiedByITDC = false ; for ( Iterator ii = newParentTarget . getType ( ) . getInterTypeMungersIncludingSupers ( ) . iterator ( ) ; ( ii . hasNext ( ) ) && ( ! satisfiedByITDC ) ; ) { ConcreteTypeMunger m = ( ( ConcreteTypeMunger ) ( ii . next ( ) ) ) ; if ( ( m . getMunger ( ) ) instanceof NewConstructorTypeMunger ) { if ( m . getSignature ( ) . getSignature ( ) . equals ( invokeSpecial . getSignature ( cpg ) ) ) { satisfiedByITDC = true ; } } } if ( ! satisfiedByITDC ) { String csig = createReadableCtorSig ( newParent , cpg , invokeSpecial ) ; weaver . getWorld ( ) . getMessageHandler ( ) . handleMessage ( MessageUtil . error ( ( ( ( ( "Unable<seq2seq4repair_space>to<seq2seq4repair_space>modify<seq2seq4repair_space>hierarchy<seq2seq4repair_space>for<seq2seq4repair_space>" + ( newParentTarget . getClassName ( ) ) ) + "<seq2seq4repair_space>-<seq2seq4repair_space>the<seq2seq4repair_space>constructor<seq2seq4repair_space>" ) + csig ) + "<seq2seq4repair_space>is<seq2seq4repair_space>missing" ) , this . getSourceLocation ( ) ) ) ; return false ; } } <START_BUG> int idx = cpg . addMethodref ( newParent . getClassName ( ) , invokeSpecial . getMethodName ( cpg ) , invokeSpecial . getSignature ( cpg ) ) ; <END_BUG> invokeSpecial . setIndex ( idx ) ; } } handle = handle . getNext ( ) ; } } } return true ; } private String createReadableCtorSig ( ResolvedType newParent , ConstantPoolGen cpg , INVOKESPECIAL invokeSpecial ) { } private ResolvedMember getConstructorWithSignature ( ResolvedType tx , String signature ) { } private boolean mungePrivilegedAccess ( BcelClassWeaver weaver , PrivilegedAccessMunger munger ) { } private void addFieldGetter ( LazyClassGen gen , ResolvedMember field , ResolvedMember accessMethod ) { } private void addFieldSetter ( LazyClassGen gen , ResolvedMember field , ResolvedMember accessMethod ) { } private void addMethodDispatch ( LazyClassGen gen , ResolvedMember method , ResolvedMember accessMethod ) { } protected LazyMethodGen makeMethodGen ( LazyClassGen gen , ResolvedMember member ) { } protected FieldGen makeFieldGen ( LazyClassGen gen , ResolvedMember member ) { } private boolean mungePerObjectInterface ( BcelClassWeaver weaver , PerObjectInterfaceTypeMunger munger ) { } private boolean mungePerTypeWithinTransformer ( BcelClassWeaver weaver ) { } private boolean couldMatch ( BcelObjectType bcelObjectType , Pointcut pointcut ) { } private boolean mungeNewMethod ( BcelClassWeaver weaver , NewMethodTypeMunger munger ) { } private void createAnyBridgeMethodsForCovariance ( BcelClassWeaver weaver , NewMethodTypeMunger munger , ResolvedMember unMangledInterMethod , ResolvedType onType , LazyClassGen gen , Type [ ] paramTypes ) { } private void createBridgeMethod ( BcelWorld world , NewMethodTypeMunger munger , ResolvedMember unMangledInterMethod , LazyClassGen clazz , Type [ ] paramTypes , ResolvedMember theBridgeMethod ) { } private boolean mungeMethodDelegate ( BcelClassWeaver weaver , MethodDelegateTypeMunger munger ) { } private ResolvedMember getRealMemberForITDFromAspect ( ResolvedType aspectType , ResolvedMember lookingFor , boolean isCtorRelated ) { } private void addNeededSuperCallMethods ( BcelClassWeaver weaver , ResolvedType onType , Set neededSuperCalls ) { } private void signalError ( String msgid , BcelClassWeaver weaver , UnresolvedType onType ) { } private boolean mungeNewConstructor ( BcelClassWeaver weaver , NewConstructorTypeMunger newConstructorTypeMunger ) { } private static LazyMethodGen makeDispatcher ( LazyClassGen onGen , String dispatchName , ResolvedMember superMethod , BcelWorld world , boolean isSuper ) { } private boolean mungeNewField ( BcelClassWeaver weaver , NewFieldTypeMunger munger ) { } private void createBridgeMethodForITDF ( BcelClassWeaver weaver , LazyClassGen gen , ResolvedMember itdfieldSetter , ResolvedMember bridgingSetter ) { } public ConcreteTypeMunger parameterizedFor ( ResolvedType target ) { } public List getTypeVariableAliases ( ) { } }

Fix:
int idx = cpg . addMethodref ( newParent . getName ( ) , invokeSpecial . getMethodName ( cpg ) , invokeSpecial . getSignature ( cpg ) ) ;