nus-yam/ex-repair huggingface dataset:
Program: 9549
Project: 9549
Buggy source:
protected void consumeExtraParameterNoFormal(){
  long pos=identifierPositionStack[identifierPtr];
  int end=(int)pos;
  int start=(int)(pos >>> 32);
  char[] name=identifierStack[identifierPtr--];
  identifierLengthPtr--;
  AdviceDeclaration adviceDecl=(AdviceDeclaration)astStack[astPtr];
  if (adviceDecl.kind != AdviceKind.After) {
  }
  if (CharOperation.equals(name,"String_Node_Str".toCharArray())) {
    adviceDecl.kind=AdviceKind.AfterThrowing;
  }
 else   if (CharOperation.equals(name,"String_Node_Str".toCharArray())) {
    adviceDecl.kind=AdviceKind.AfterReturning;
  }
 else {
  }
}

Fixed version (ground truth):
protected void consumeExtraParameterNoFormal(){
  long pos=identifierPositionStack[identifierPtr];
  int end=(int)pos;
  int start=(int)(pos >>> 32);
  char[] name=identifierStack[identifierPtr--];
  identifierLengthPtr--;
  AdviceDeclaration adviceDecl=(AdviceDeclaration)astStack[astPtr];
  if (adviceDecl.kind != AdviceKind.After) {
  }
  if (CharOperation.equals(name,"String_Node_Str".toCharArray())) {
    adviceDecl.kind=AdviceKind.AfterThrowing;
  }
 else   if (CharOperation.equals(name,"String_Node_Str".toCharArray())) {
    adviceDecl.kind=AdviceKind.AfterReturning;
  }
 else {
    problemReporter().parseError(start,end,name,String.valueOf(name),new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"});
  }
}
Program: 9550
Project: 9550
Buggy source:
private void replaceEffectivelyStaticRef(MessageSend call){
  NameReference receiver=(NameReference)call.receiver;
  receiver.binding=thisJoinPointStaticPartDecLocal;
  receiver.codegenBinding=thisJoinPointStaticPartDecLocal;
  call.binding=call.codegenBinding=getEquivalentStaticBinding(call.binding);
}

Fixed version (ground truth):
private void replaceEffectivelyStaticRef(MessageSend call){
  NameReference receiver=(NameReference)call.receiver;
  receiver.binding=thisJoinPointStaticPartDecLocal;
  receiver.codegenBinding=thisJoinPointStaticPartDecLocal;
  ReferenceBinding thisJoinPointStaticPartType=(ReferenceBinding)thisJoinPointStaticPartDec.type;
  receiver.receiverType=receiver.actualReceiverType=receiver.resolvedType=thisJoinPointStaticPartType;
  call.setActualReceiverType(thisJoinPointStaticPartType);
  call.binding=call.codegenBinding=getEquivalentStaticBinding(call.binding);
}
Program: 9551
Project: 9551
Buggy source:
public void setJavac(Javac javac){
  this.javac=javac;
}

Fixed version (ground truth):
public void setJavac(Javac javac){
  this.javac=javac;
  javac.setTaskName(javac.getTaskName() + "String_Node_Str");
}
Program: 9552
Project: 9552
Buggy source:
public boolean execute() throws BuildException {
  checkJavac();
  if (recurse()) {
    javac.execute();
  }
 else {
    try {
      AjcTask ajc=new AjcTask();
      String err=ajc.setupAjc(javac);
      if (null != err) {
        throw new BuildException(err,javac.getLocation());
      }
      ajc.execute();
    }
  finally {
      doneRecursing();
    }
  }
  return true;
}

Fixed version (ground truth):
public boolean execute() throws BuildException {
  if (null == javac) {
    throw new IllegalStateException("String_Node_Str");
  }
  if (!((Boolean)inSelfCall.get()).booleanValue() && afterCleaningDirs()) {
    inSelfCall.set(Boolean.TRUE);
    javac.execute();
  }
 else {
    try {
      AjcTask ajc=new AjcTask();
      String err=ajc.setupAjc(javac);
      if (null != err) {
        throw new BuildException(err,javac.getLocation());
      }
      ajc.execute();
    }
  finally {
      inSelfCall.set(Boolean.FALSE);
    }
  }
  return true;
}
Program: 9554
Project: 9554
Buggy source:
/** 
 * Compile using ajc per settings.
 * @exception BuildException if the compilation has problemsor if there were compiler errors and failonerror is true.
 */
public void execute() throws BuildException {
  if (executing) {
    throw new IllegalStateException("String_Node_Str");
  }
 else {
    executing=true;
  }
  verifyOptions();
  try {
    String[] args=makeCommand();
    if (verbose || listFileArgs) {
      log("String_Node_Str" + Arrays.asList(args),Project.MSG_VERBOSE);
    }
    if (!fork) {
      executeInSameVM(args);
    }
 else {
      executeInOtherVM(args);
    }
  }
 catch (  BuildException e) {
    throw e;
  }
catch (  Throwable x) {
    System.err.println(Main.renderExceptionForUser(x));
    throw new BuildException("String_Node_Str" + LangUtil.unqualifiedClassName(x) + "String_Node_Str");
  }
 finally {
    executing=false;
    if (null != tmpOutjar) {
      tmpOutjar.delete();
    }
  }
}

Fixed version (ground truth):
/** 
 * Compile using ajc per settings.
 * @exception BuildException if the compilation has problemsor if there were compiler errors and failonerror is true.
 */
public void execute() throws BuildException {
  if (executing) {
    throw new IllegalStateException("String_Node_Str");
  }
 else {
    executing=true;
  }
  setupOptions();
  verifyOptions();
  try {
    String[] args=makeCommand();
    if (verbose || listFileArgs) {
      log("String_Node_Str" + Arrays.asList(args),Project.MSG_VERBOSE);
    }
    if (!fork) {
      executeInSameVM(args);
    }
 else {
      executeInOtherVM(args);
    }
  }
 catch (  BuildException e) {
    throw e;
  }
catch (  Throwable x) {
    System.err.println(Main.renderExceptionForUser(x));
    throw new BuildException("String_Node_Str" + LangUtil.unqualifiedClassName(x) + "String_Node_Str");
  }
 finally {
    executing=false;
    if (null != tmpOutjar) {
      tmpOutjar.delete();
    }
  }
}
Program: 9555
Project: 9555
Buggy source:
/** 
 * to use this same Task more than once (testing) 
 */
public void reset(){
  adapterArguments=null;
  adapterFiles=new ArrayList();
  argfiles=null;
  executing=false;
  aspectpath=null;
  bootclasspath=null;
  classpath=null;
  cmd=new GuardedCommand();
  copyInjars=false;
  destDir=DEFAULT_DESTDIR;
  executing=false;
  executingInOtherVM=false;
  extdirs=null;
  failonerror=true;
  forkclasspath=null;
  inIncrementalMode=false;
  inIncrementalFileMode=false;
  ignored=new ArrayList();
  injars=null;
  listFileArgs=false;
  maxMem=null;
  messageHolder=null;
  outjar=null;
  sourceRootCopyFilter=null;
  sourceRoots=null;
  srcdir=null;
  tmpOutjar=null;
  verbose=false;
}

Fixed version (ground truth):
/** 
 * to use this same Task more than once (testing) 
 */
public void reset(){
  adapterArguments=null;
  adapterFiles=new ArrayList();
  argfiles=null;
  executing=false;
  aspectpath=null;
  bootclasspath=null;
  classpath=null;
  cmd=new GuardedCommand();
  copyInjars=false;
  destDir=DEFAULT_DESTDIR;
  executing=false;
  executingInOtherVM=false;
  extdirs=null;
  failonerror=true;
  forkclasspath=null;
  inIncrementalMode=false;
  inIncrementalFileMode=false;
  ignored=new ArrayList();
  injars=null;
  listFileArgs=false;
  maxMem=null;
  messageHolder=null;
  outjar=null;
  sourceRootCopyFilter=null;
  sourceRoots=null;
  srcdir=null;
  tmpOutjar=null;
  verbose=false;
  xweaveDir=null;
}
Program: 9557
Project: 9557
Buggy source:
public static void checkerMunger(IHierarchy model,Shadow shadow,Checker checker){
  if (shadow.getSourceLocation() == null || checker.getSourceLocation() == null)   return;
  String sourceHandle=ProgramElement.createHandleIdentifier(checker.getSourceLocation().getSourceFile(),checker.getSourceLocation().getLine(),checker.getSourceLocation().getColumn());
  String targetHandle=ProgramElement.createHandleIdentifier(shadow.getSourceLocation().getSourceFile(),shadow.getSourceLocation().getLine(),shadow.getSourceLocation().getColumn());
  IRelationshipMap mapper=AsmManager.getDefault().getRelationshipMap();
  if (sourceHandle != null && targetHandle != null) {
    IRelationship foreward=mapper.get(sourceHandle,IRelationship.Kind.DECLARE,MATCHED_BY);
    foreward.getTargets().add(targetHandle);
    IRelationship back=mapper.get(targetHandle,IRelationship.Kind.DECLARE,MATCHES_DECLARE);
    back.getTargets().add(sourceHandle);
  }
}

Fixed version (ground truth):
public static void checkerMunger(IHierarchy model,Shadow shadow,Checker checker){
  if (shadow.getSourceLocation() == null || checker.getSourceLocation() == null)   return;
  String sourceHandle=ProgramElement.createHandleIdentifier(checker.getSourceLocation().getSourceFile(),checker.getSourceLocation().getLine(),checker.getSourceLocation().getColumn());
  String targetHandle=ProgramElement.createHandleIdentifier(shadow.getSourceLocation().getSourceFile(),shadow.getSourceLocation().getLine(),shadow.getSourceLocation().getColumn());
  IRelationshipMap mapper=AsmManager.getDefault().getRelationshipMap();
  if (sourceHandle != null && targetHandle != null) {
    IRelationship foreward=mapper.get(sourceHandle,IRelationship.Kind.DECLARE,MATCHED_BY);
    foreward.getTargets().add(targetHandle);
    IRelationship back=mapper.get(targetHandle,IRelationship.Kind.DECLARE,MATCHES_DECLARE);
    if (back != null && back.getTargets() != null) {
      back.getTargets().add(sourceHandle);
    }
  }
}
Program: 9560
Project: 9560
Buggy source:
public void buildInterTypeAndPerClause(ClassScope classScope){
  factory=EclipseFactory.fromScopeLookupEnvironment(scope);
  if (isPrivileged) {
    binding.privilegedHandler=new PrivilegedHandler(this);
  }
  checkSpec(classScope);
  if (ignoreFurtherInvestigation)   return;
  buildPerClause(scope);
  if (methods != null) {
    for (int i=0; i < methods.length; i++) {
      if (methods[i] instanceof InterTypeDeclaration) {
        EclipseTypeMunger m=((InterTypeDeclaration)methods[i]).build(classScope);
        if (m != null)         concreteName.typeMungers.add(m);
      }
 else       if (methods[i] instanceof DeclareDeclaration) {
        Declare d=((DeclareDeclaration)methods[i]).build(classScope);
        if (d != null)         concreteName.declares.add(d);
      }
    }
  }
  factory.getWorld().getCrosscuttingMembersSet().addOrReplaceAspect(typeX);
  if (typeX.getSuperclass().isAspect() && !typeX.getSuperclass().isExposedToWeaver()) {
    factory.getWorld().getCrosscuttingMembersSet().addOrReplaceAspect(typeX.getSuperclass());
  }
}

Fixed version (ground truth):
public void buildInterTypeAndPerClause(ClassScope classScope){
  factory=EclipseFactory.fromScopeLookupEnvironment(scope);
  if (isPrivileged) {
    binding.privilegedHandler=new PrivilegedHandler(this);
  }
  checkSpec(classScope);
  if (ignoreFurtherInvestigation)   return;
  buildPerClause(scope);
  if (methods != null) {
    for (int i=0; i < methods.length; i++) {
      if (methods[i] instanceof InterTypeDeclaration) {
        EclipseTypeMunger m=((InterTypeDeclaration)methods[i]).build(classScope);
        if (m != null)         concreteName.typeMungers.add(m);
      }
 else       if (methods[i] instanceof DeclareDeclaration) {
        Declare d=((DeclareDeclaration)methods[i]).build(classScope);
        if (d != null)         concreteName.declares.add(d);
      }
    }
  }
  concreteName.getDeclaredPointcuts();
}
Program: 9561
Project: 9561
Buggy source:
public ResolvedPointcutDefinition makeResolvedPointcutDefinition(){
  ResolvedPointcutDefinition ret=new ResolvedPointcutDefinition(EclipseFactory.fromBinding(this.binding.declaringClass),declaredModifiers,declaredName,EclipseFactory.fromBindings(this.binding.parameters),getPointcut());
  ret.setPosition(sourceStart,sourceEnd);
  ret.setSourceContext(new EclipseSourceContext(compilationResult));
  return ret;
}

Fixed version (ground truth):
public ResolvedPointcutDefinition makeResolvedPointcutDefinition(){
  if (resolvedPointcutDeclaration != null)   return resolvedPointcutDeclaration;
  resolvedPointcutDeclaration=new ResolvedPointcutDefinition(EclipseFactory.fromBinding(this.binding.declaringClass),declaredModifiers,declaredName,EclipseFactory.fromBindings(this.binding.parameters),getPointcut());
  resolvedPointcutDeclaration.setPosition(sourceStart,sourceEnd);
  resolvedPointcutDeclaration.setSourceContext(new EclipseSourceContext(compilationResult));
  return resolvedPointcutDeclaration;
}
Program: 9562
Project: 9562
Buggy source:
public void resolveStatements(){
  if (isAbstract()) {
    this.modifiers|=AccSemicolonBody;
  }
  if (binding == null || ignoreFurtherInvestigation)   return;
  if (Modifier.isAbstract(this.declaredModifiers) && (pointcutDesignator != null)) {
    scope.problemReporter().signalError(sourceStart,sourceEnd,"String_Node_Str");
    ignoreFurtherInvestigation=true;
    return;
  }
  if (pointcutDesignator != null) {
    pointcutDesignator.finishResolveTypes(this,this.binding,arguments.length,scope.enclosingSourceType());
  }
  super.resolveStatements();
}

Fixed version (ground truth):
public void resolveStatements(){
  if (isAbstract()) {
    this.modifiers|=AccSemicolonBody;
  }
  if (binding == null || ignoreFurtherInvestigation)   return;
  if (Modifier.isAbstract(this.declaredModifiers) && (pointcutDesignator != null)) {
    scope.problemReporter().signalError(sourceStart,sourceEnd,"String_Node_Str");
    ignoreFurtherInvestigation=true;
    return;
  }
  if (pointcutDesignator != null) {
    pointcutDesignator.finishResolveTypes(this,this.binding,arguments.length,scope.enclosingSourceType());
  }
  makeResolvedPointcutDefinition();
  resolvedPointcutDeclaration.setPointcut(getPointcut());
  super.resolveStatements();
}
Program: 9563
Project: 9563
Buggy source:
public void completeTypeBindings(){
  stepCompleted=BUILD_TYPE_HIERARCHY;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.checkAndSetImports();
  }
  stepCompleted=CHECK_AND_SET_IMPORTS;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.connectTypeHierarchy();
  }
  stepCompleted=CONNECT_TYPE_HIERARCHY;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.buildFieldsAndMethods();
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      factory.addSourceTypeBinding(b[j]);
    }
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      buildInterTypeAndPerClause(b[j].scope);
    }
  }
  factory.finishTypeMungers();
  Collection typeMungers=factory.getTypeMungers();
  Collection declareParents=factory.getDeclareParents();
  doPendingWeaves();
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    weaveInterTypeDeclarations(units[i].scope,typeMungers,declareParents);
    units[i]=null;
  }
  stepCompleted=BUILD_FIELDS_AND_METHODS;
  lastCompletedUnitIndex=lastUnitIndex;
}

Fixed version (ground truth):
public void completeTypeBindings(){
  stepCompleted=BUILD_TYPE_HIERARCHY;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.checkAndSetImports();
  }
  stepCompleted=CHECK_AND_SET_IMPORTS;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.connectTypeHierarchy();
  }
  stepCompleted=CONNECT_TYPE_HIERARCHY;
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    units[i].scope.buildFieldsAndMethods();
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      factory.addSourceTypeBinding(b[j]);
    }
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      buildInterTypeAndPerClause(b[j].scope);
    }
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      resolvePointcutDeclarations(b[j].scope);
    }
  }
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    SourceTypeBinding[] b=units[i].scope.topLevelTypes;
    for (int j=0; j < b.length; j++) {
      addCrosscuttingStructures(b[j].scope);
    }
  }
  factory.finishTypeMungers();
  Collection typeMungers=factory.getTypeMungers();
  Collection declareParents=factory.getDeclareParents();
  doPendingWeaves();
  for (int i=lastCompletedUnitIndex + 1; i <= lastUnitIndex; i++) {
    weaveInterTypeDeclarations(units[i].scope,typeMungers,declareParents);
    units[i]=null;
  }
  stepCompleted=BUILD_FIELDS_AND_METHODS;
  lastCompletedUnitIndex=lastUnitIndex;
}
Program: 9565
Project: 9565
Buggy source:
public String toLinkLabelString(){
  String label;
  if (kind == Kind.CODE || kind == Kind.INITIALIZER) {
    label=parent.getParent().getName() + "String_Node_Str";
  }
 else   if (kind.isInterTypeMemberKind()) {
    int dotIndex=name.indexOf('.');
    if (dotIndex != -1) {
      return parent.getName() + "String_Node_Str" + toLabelString().substring(dotIndex + 1);
    }
 else {
      label=parent.getName() + '.';
    }
  }
 else   if (kind == Kind.CLASS || kind == Kind.ASPECT) {
    label="String_Node_Str";
  }
 else {
    label=parent.getName() + '.';
  }
  label+=toLabelString();
  return label;
}

Fixed version (ground truth):
/** 
 * TODO: move the "parent != null"==>injar heuristic to more explicit 
 */
public String toLinkLabelString(){
  String label;
  if (kind == Kind.CODE || kind == Kind.INITIALIZER) {
    label=parent.getParent().getName() + "String_Node_Str";
  }
 else   if (kind.isInterTypeMemberKind()) {
    int dotIndex=name.indexOf('.');
    if (dotIndex != -1) {
      return parent.getName() + "String_Node_Str" + toLabelString().substring(dotIndex + 1);
    }
 else {
      label=parent.getName() + '.';
    }
  }
 else   if (kind == Kind.CLASS || kind == Kind.ASPECT) {
    label="String_Node_Str";
  }
 else {
    if (parent != null) {
      label=parent.getName() + '.';
    }
 else {
      label="String_Node_Str";
    }
  }
  label+=toLabelString();
  return label;
}
Program: 9566
Project: 9566
Buggy source:
private PerClause.Kind lookupPerClauseKind(ReferenceBinding binding){
  if (binding instanceof SourceTypeBinding && !(binding instanceof BinaryTypeBinding)) {
    SourceTypeBinding sourceSc=(SourceTypeBinding)binding;
    if (sourceSc.scope.referenceContext instanceof AspectDeclaration) {
      PerClause perClause=((AspectDeclaration)sourceSc.scope.referenceContext).perClause;
      if (perClause == null)       return lookupPerClauseKind(binding.superclass());
 else       return perClause.getKind();
    }
 else {
      return null;
    }
  }
 else {
    return null;
  }
}

Fixed version (ground truth):
private PerClause.Kind lookupPerClauseKind(ReferenceBinding binding){
  PerClause perClause;
  if (binding instanceof BinaryTypeBinding) {
    ResolvedTypeX superTypeX=factory.fromEclipse(binding);
    perClause=superTypeX.getPerClause();
  }
 else   if (binding instanceof SourceTypeBinding) {
    SourceTypeBinding sourceSc=(SourceTypeBinding)binding;
    if (sourceSc.scope.referenceContext instanceof AspectDeclaration) {
      perClause=((AspectDeclaration)sourceSc.scope.referenceContext).perClause;
    }
 else {
      return null;
    }
  }
 else {
    return null;
  }
  if (perClause == null) {
    return lookupPerClauseKind(binding.superclass());
  }
 else {
    return perClause.getKind();
  }
}
Program: 9567
Project: 9567
Buggy source:
/** 
 * @return a String suitable as an inlined DOCTYPE statement 
 */
public static String inlineDocType(){
  return "String_Node_Str" + AjcTest.Suite.Spec.XMLNAME + "String_Node_Str"+ AjcSpecXmlReader.getDocType()+ EOL+ "String_Node_Str";
}

Fixed version (ground truth):
/** 
 * @deprecated
 * @return a String suitable as an inlined DOCTYPE statement 
 */
public static String inlineDocType(){
  return "String_Node_Str" + AjcTest.Suite.Spec.XMLNAME + "String_Node_Str"+ AjcSpecXmlReader.getDocType()+ EOL+ "String_Node_Str";
}
Program: 9568
Project: 9568
Buggy source:
/** 
 * Write a DTD to dtdFile.
 * @param dtdFile the File to write to
 */
public static void writeDTD(File dtdFile) throws IOException {
  LangUtil.throwIaxIfNull(dtdFile,"String_Node_Str");
  PrintWriter out=new PrintWriter(new FileWriter(dtdFile));
  try {
    out.println("String_Node_Str" + AjcSpecXmlReader.class.getName() + "String_Node_Str");
    out.println(getDocType());
  }
  finally {
    out.close();
  }
}

Fixed version (ground truth):
/** 
 * Write a DTD to dtdFile.
 * @deprecated
 * @param dtdFile the File to write to
 */
public static void writeDTD(File dtdFile) throws IOException {
  LangUtil.throwIaxIfNull(dtdFile,"String_Node_Str");
  PrintWriter out=new PrintWriter(new FileWriter(dtdFile));
  try {
    out.println("String_Node_Str" + AjcSpecXmlReader.class.getName() + "String_Node_Str");
    out.println(getDocType());
  }
  finally {
    out.close();
  }
}
Program: 9569
Project: 9569
Buggy source:
/** 
 * Read the specifications for a suite of AjcTest from an XML file. This also sets the suite dir in the specification.
 * @param file the File must be readable, comply with DOCTYPE.
 * @return AjcTest.Suite.Spec read from file
 * @see setLogLevel(int)
 */
public AjcTest.Suite.Spec readAjcSuite(File file) throws IOException, AbortException {
  System.setProperty("String_Node_Str","String_Node_Str");
  System.setProperty("String_Node_Str",LOG[logLevel]);
  final Digester digester=new Digester();
  setupDigester(digester);
  SuiteHolder holder=new SuiteHolder();
  digester.push(holder);
  FileInputStream input=new FileInputStream(file);
  try {
    digester.parse(input);
  }
 catch (  SAXException e) {
    MessageUtil.fail("String_Node_Str" + file,e);
  }
 finally {
    if (null != input) {
      input.close();
      input=null;
    }
  }
  AjcTest.Suite.Spec result=holder.spec;
  if (null != result) {
    file=file.getAbsoluteFile();
    result.setSourceLocation(new SourceLocation(file,1));
    File suiteDir=file.getParentFile();
    if (null == suiteDir) {
      suiteDir=new File("String_Node_Str");
    }
    result.setSuiteDirFile(suiteDir);
    if (result.runtime.isVerbose()) {
      RunUtils.enableVerbose(result);
    }
  }
  return result;
}

Fixed version (ground truth):
/** 
 * Read the specifications for a suite of AjcTest from an XML file. This also sets the suite dir in the specification.
 * @param file the File must be readable, comply with DOCTYPE.
 * @return AjcTest.Suite.Spec read from file
 * @see setLogLevel(int)
 */
public AjcTest.Suite.Spec readAjcSuite(File file) throws IOException, AbortException {
  System.setProperty("String_Node_Str","String_Node_Str");
  System.setProperty("String_Node_Str",LOG[logLevel]);
  final Digester digester=makeDigester(file);
  SuiteHolder holder=new SuiteHolder();
  digester.push(holder);
  FileInputStream input=new FileInputStream(file);
  try {
    digester.parse(input);
  }
 catch (  SAXException e) {
    MessageUtil.fail("String_Node_Str" + file,e);
  }
 finally {
    if (null != input) {
      input.close();
      input=null;
    }
  }
  AjcTest.Suite.Spec result=holder.spec;
  if (null != result) {
    file=file.getAbsoluteFile();
    result.setSourceLocation(new SourceLocation(file,1));
    File suiteDir=file.getParentFile();
    if (null == suiteDir) {
      suiteDir=new File("String_Node_Str");
    }
    result.setSuiteDirFile(suiteDir);
    if (result.runtime.isVerbose()) {
      RunUtils.enableVerbose(result);
    }
  }
  return result;
}
Program: 9572
Project: 9572
Buggy source:
public int compare(Object o1,Object o2){
  IProgramElement sv1=((IStructureViewNode)o1).getStructureNode();
  IProgramElement sv2=((IStructureViewNode)o2).getStructureNode();
  if (sv1 instanceof IProgramElement && sv2 instanceof IProgramElement) {
    IProgramElement p1=(IProgramElement)sv1;
    IProgramElement p2=(IProgramElement)sv2;
    if (p1.getSourceLocation() == null) {
      return 0;
    }
 else     if (p1.getSourceLocation().getLine() < p2.getSourceLocation().getLine()) {
      return -1;
    }
 else {
      return 1;
    }
  }
 else {
    return 0;
  }
}

Fixed version (ground truth):
public int compare(Object o1,Object o2){
  IProgramElement sv1=((IStructureViewNode)o1).getStructureNode();
  IProgramElement sv2=((IStructureViewNode)o2).getStructureNode();
  if (sv1 instanceof IProgramElement && sv2 instanceof IProgramElement) {
    IProgramElement p1=(IProgramElement)sv1;
    IProgramElement p2=(IProgramElement)sv2;
    if (p2.getKind() == IProgramElement.Kind.IMPORT_REFERENCE)     return 1;
    if (p1.getKind() == IProgramElement.Kind.IMPORT_REFERENCE)     return -1;
    if (p1.getSourceLocation() == null || p2.getSourceLocation() == null) {
      return 0;
    }
 else     if (p1.getSourceLocation().getLine() < p2.getSourceLocation().getLine()) {
      return -1;
    }
 else {
      return 1;
    }
  }
 else {
    return 0;
  }
}
Program: 9573
Project: 9573
Buggy source:
private void expandTree(int depth){
  for (int i=0; i < structureTree.getRowCount(); i++) {
    TreePath path=structureTree.getPathForRow(i);
    SwingTreeViewNode node=(SwingTreeViewNode)path.getLastPathComponent();
    if (path.getPath().length - 1 > depth || node.getUserObject() instanceof IRelationship) {
      structureTree.collapsePath(path);
    }
 else {
      structureTree.expandPath(path);
    }
  }
  structureTree.expandPath(structureTree.getPathForRow(0));
}

Fixed version (ground truth):
private void expandTree(int depth){
  for (int i=0; i < structureTree.getRowCount(); i++) {
    TreePath path=structureTree.getPathForRow(i);
    SwingTreeViewNode node=(SwingTreeViewNode)path.getLastPathComponent();
    if (path.getPath().length - 1 > depth || node.getKind() == IStructureViewNode.Kind.RELATIONSHIP) {
      structureTree.collapsePath(path);
    }
 else {
      structureTree.expandPath(path);
    }
  }
  structureTree.expandPath(structureTree.getPathForRow(0));
}
Program: 9574
Project: 9574
Buggy source:
private void highlightNode(SwingTreeViewNode parent,IProgramElement node){
  for (int i=0; i < parent.getChildCount(); i++) {
    SwingTreeViewNode currNode=(SwingTreeViewNode)parent.getChildAt(i);
    IProgramElement sNode=(IProgramElement)currNode.getUserObject();
    if (sNode instanceof IProgramElement && ((IProgramElement)sNode).equals(node)) {
      TreePath path=new TreePath(currNode.getPath());
      structureTree.setSelectionPath(path);
      int currRow=structureTree.getRowForPath(path);
      structureTree.expandRow(currRow);
      structureTree.scrollRowToVisible(currRow);
    }
 else {
      highlightNode(currNode,node);
    }
  }
}

Fixed version (ground truth):
private void highlightNode(SwingTreeViewNode parent,IProgramElement node){
  for (int i=0; i < parent.getChildCount(); i++) {
    SwingTreeViewNode currNode=(SwingTreeViewNode)parent.getChildAt(i);
    IProgramElement sNode=(IProgramElement)currNode.getStructureNode();
    if (sNode != null && sNode.equals(node) && currNode.getKind() != IStructureViewNode.Kind.LINK) {
      TreePath path=new TreePath(currNode.getPath());
      structureTree.setSelectionPath(path);
      int currRow=structureTree.getRowForPath(path);
      structureTree.expandRow(currRow);
      structureTree.scrollRowToVisible(currRow);
    }
 else {
      highlightNode(currNode,node);
    }
  }
}
Program: 9575
Project: 9575
Buggy source:
public void setActiveNode(IStructureViewNode node,int lineOffset){
  if (node == null)   return;
  if (!(node.getStructureNode() instanceof IProgramElement))   return;
  IProgramElement pNode=(IProgramElement)node.getStructureNode();
  treeManager.highlightNode(pNode);
  if (pNode.getSourceLocation() != null) {
    Ajde.getDefault().getEditorAdapter().showSourceLine(pNode.getSourceLocation().getSourceFile().getAbsolutePath(),pNode.getSourceLocation().getLine() + lineOffset,true);
  }
}

Fixed version (ground truth):
public void setActiveNode(IStructureViewNode node,int lineOffset){
  if (node == null)   return;
  IProgramElement pNode=(IProgramElement)node.getStructureNode();
  treeManager.highlightNode(pNode);
  if (pNode.getSourceLocation() != null) {
    Ajde.getDefault().getEditorAdapter().showSourceLine(pNode.getSourceLocation().getSourceFile().getAbsolutePath(),pNode.getSourceLocation().getLine() + lineOffset,true);
  }
}
Program: 9576
Project: 9576
Buggy source:
public void test(){
  String testLstFile="String_Node_Str";
  File f=new File(testLstFile);
  assertTrue(testLstFile,f.canRead());
  assertTrue("String_Node_Str" + testLstFile,verifyAgainstSavedModel(testLstFile));
}

Fixed version (ground truth):
public void test(){
  String testLstFile="String_Node_Str";
  File f=new File(testLstFile);
  assertTrue(testLstFile,f.canRead());
}
Program: 9577
Project: 9577
Buggy source:
public void testFileNodeFind() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceLine(testFile.getCanonicalPath(),1);
  assertTrue("String_Node_Str",node != null);
  assertEquals("String_Node_Str",2,node.getChildren().size());
  IProgramElement pNode=(IProgramElement)node;
  assertTrue("String_Node_Str" + pNode.getName(),pNode.getKind().equals(IProgramElement.Kind.FILE_JAVA));
}

Fixed version (ground truth):
public void testFileNodeFind() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceLine(testFile.getCanonicalPath(),1);
  assertTrue("String_Node_Str",node != null);
  assertEquals("String_Node_Str",3,node.getChildren().size());
  IProgramElement pNode=(IProgramElement)node;
  assertTrue("String_Node_Str" + pNode.getName(),pNode.getKind().equals(IProgramElement.Kind.FILE_JAVA));
}
Program: 9578
Project: 9578
Buggy source:
public void testPointcutName() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceFile(testFile.getAbsolutePath());
  assertTrue("String_Node_Str",node != null);
  IProgramElement pNode=(IProgramElement)((IProgramElement)node).getChildren().get(1);
  IProgramElement pointcut=(IProgramElement)pNode.getChildren().get(0);
  assertTrue("String_Node_Str",pointcut.getKind().equals(IProgramElement.Kind.POINTCUT));
  assertTrue("String_Node_Str" + pointcut.getName(),pointcut.toLabelString().equals("String_Node_Str"));
}

Fixed version (ground truth):
public void testPointcutName() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceFile(testFile.getAbsolutePath());
  assertTrue("String_Node_Str",node != null);
  IProgramElement pNode=(IProgramElement)((IProgramElement)node).getChildren().get(2);
  IProgramElement pointcut=(IProgramElement)pNode.getChildren().get(0);
  assertTrue("String_Node_Str",pointcut.getKind().equals(IProgramElement.Kind.POINTCUT));
  assertTrue("String_Node_Str" + pointcut.getName(),pointcut.toLabelString().equals("String_Node_Str"));
}
Program: 9579
Project: 9579
Buggy source:
public void testRootForSourceFile() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceFile(testFile.getAbsolutePath());
  assertTrue("String_Node_Str",node != null);
  IProgramElement pNode=(IProgramElement)node;
  String child=((IProgramElement)pNode.getChildren().get(0)).getName();
  assertTrue("String_Node_Str" + child,child.equals("String_Node_Str"));
}

Fixed version (ground truth):
public void testRootForSourceFile() throws IOException {
  File testFile=openFile("String_Node_Str");
  IProgramElement node=Ajde.getDefault().getStructureModelManager().getHierarchy().findElementForSourceFile(testFile.getAbsolutePath());
  assertTrue("String_Node_Str",node != null);
  IProgramElement pNode=(IProgramElement)node;
  String child=((IProgramElement)pNode.getChildren().get(1)).getName();
  assertTrue("String_Node_Str" + child,child.equals("String_Node_Str"));
}
Program: 9580
Project: 9580
Buggy source:
private static List genModifiers(int modifiers){
  List modifiersList=new ArrayList();
  if ((modifiers & AccStatic) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccFinal) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccSynchronized) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccVolatile) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccTransient) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccNative) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccAbstract) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  return modifiersList;
}

Fixed version (ground truth):
private static List genModifiers(int modifiers){
  List modifiersList=new ArrayList();
  if ((modifiers & AccStatic) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccFinal) != 0)   modifiersList.add(IProgramElement.Modifiers.FINAL);
  if ((modifiers & AccSynchronized) != 0)   modifiersList.add(IProgramElement.Modifiers.SYNCHRONIZED);
  if ((modifiers & AccVolatile) != 0)   modifiersList.add(IProgramElement.Modifiers.VOLATILE);
  if ((modifiers & AccTransient) != 0)   modifiersList.add(IProgramElement.Modifiers.TRANSIENT);
  if ((modifiers & AccNative) != 0)   modifiersList.add(IProgramElement.Modifiers.NATIVE);
  if ((modifiers & AccAbstract) != 0)   modifiersList.add(IProgramElement.Modifiers.ABSTRACT);
  return modifiersList;
}
Program: 9581
Project: 9581
Buggy source:
/** 
 * Called only by  build(CompilationUnitDeclaration unit, StructureModel structureModel) 
 */
private void internalBuild(CompilationUnitDeclaration unit,IHierarchy structureModel){
  LangUtil.throwIaxIfNull(structureModel,"String_Node_Str");
  if (!currCompilationResult.equals(unit.compilationResult())) {
    throw new IllegalArgumentException("String_Node_Str" + unit);
  }
  final File file=new File(new String(unit.getFileName()));
  final IProgramElement cuNode;
{
    int startLine=getStartLine(unit);
    int endLine=getEndLine(unit);
    ISourceLocation sourceLocation=new SourceLocation(file,startLine,endLine);
    cuNode=new ProgramElement(new String(file.getName()),IProgramElement.Kind.FILE_JAVA,sourceLocation,0,"String_Node_Str",new ArrayList());
  }
  final IProgramElement addToNode=genAddToNode(unit,structureModel);
  for (ListIterator itt=addToNode.getChildren().listIterator(); itt.hasNext(); ) {
    IProgramElement child=(IProgramElement)itt.next();
    ISourceLocation childLoc=child.getSourceLocation();
    if (null == childLoc) {
    }
 else     if (childLoc.getSourceFile().equals(file)) {
      itt.remove();
    }
  }
  addToNode.addChild(cuNode);
  stack.push(cuNode);
  unit.traverse(this,unit.scope);
  try {
    structureModel.addToFileMap(file.getCanonicalPath(),cuNode);
  }
 catch (  IOException e) {
    System.err.println("String_Node_Str" + e.getMessage() + "String_Node_Str"+ file);
  }
}

Fixed version (ground truth):
/** 
 * Called only by  build(CompilationUnitDeclaration unit, StructureModel structureModel) 
 */
private void internalBuild(CompilationUnitDeclaration unit,IHierarchy structureModel){
  LangUtil.throwIaxIfNull(structureModel,"String_Node_Str");
  if (!currCompilationResult.equals(unit.compilationResult())) {
    throw new IllegalArgumentException("String_Node_Str" + unit);
  }
  final File file=new File(new String(unit.getFileName()));
  final IProgramElement cuNode;
{
    int startLine=getStartLine(unit);
    int endLine=getEndLine(unit);
    ISourceLocation sourceLocation=new SourceLocation(file,startLine,endLine);
    cuNode=new ProgramElement(new String(file.getName()),IProgramElement.Kind.FILE_JAVA,sourceLocation,0,"String_Node_Str",new ArrayList());
  }
  cuNode.addChild(new ProgramElement("String_Node_Str",IProgramElement.Kind.IMPORT_REFERENCE,null,0,"String_Node_Str",new ArrayList()));
  final IProgramElement addToNode=genAddToNode(unit,structureModel);
  for (ListIterator itt=addToNode.getChildren().listIterator(); itt.hasNext(); ) {
    IProgramElement child=(IProgramElement)itt.next();
    ISourceLocation childLoc=child.getSourceLocation();
    if (null == childLoc) {
    }
 else     if (childLoc.getSourceFile().equals(file)) {
      itt.remove();
    }
  }
  addToNode.addChild(cuNode);
  stack.push(cuNode);
  unit.traverse(this,unit.scope);
  try {
    structureModel.addToFileMap(file.getCanonicalPath(),cuNode);
  }
 catch (  IOException e) {
    System.err.println("String_Node_Str" + e.getMessage() + "String_Node_Str"+ file);
  }
}
Program: 9582
Project: 9582
Buggy source:
public static void checkerMunger(IHierarchy model,Shadow shadow,Checker checker){
  if (shadow.getSourceLocation() == null || checker == null)   return;
  String sourceHandle=ProgramElement.createHandleIdentifier(checker.getSourceLocation().getSourceFile(),checker.getSourceLocation().getLine(),checker.getSourceLocation().getColumn());
  String targetHandle=ProgramElement.createHandleIdentifier(shadow.getSourceLocation().getSourceFile(),shadow.getSourceLocation().getLine(),shadow.getSourceLocation().getColumn());
  IRelationshipMap mapper=AsmManager.getDefault().getRelationshipMap();
  if (sourceHandle != null && targetHandle != null) {
    IRelationship foreward=mapper.get(sourceHandle,IRelationship.Kind.DECLARE,MATCHED_BY);
    foreward.getTargets().add(targetHandle);
    IRelationship back=mapper.get(targetHandle,IRelationship.Kind.DECLARE,MATCHES_DECLARE);
    back.getTargets().add(sourceHandle);
  }
}

Fixed version (ground truth):
public static void checkerMunger(IHierarchy model,Shadow shadow,Checker checker){
  if (shadow.getSourceLocation() == null || checker.getSourceLocation() == null)   return;
  String sourceHandle=ProgramElement.createHandleIdentifier(checker.getSourceLocation().getSourceFile(),checker.getSourceLocation().getLine(),checker.getSourceLocation().getColumn());
  String targetHandle=ProgramElement.createHandleIdentifier(shadow.getSourceLocation().getSourceFile(),shadow.getSourceLocation().getLine(),shadow.getSourceLocation().getColumn());
  IRelationshipMap mapper=AsmManager.getDefault().getRelationshipMap();
  if (sourceHandle != null && targetHandle != null) {
    IRelationship foreward=mapper.get(sourceHandle,IRelationship.Kind.DECLARE,MATCHED_BY);
    foreward.getTargets().add(targetHandle);
    IRelationship back=mapper.get(targetHandle,IRelationship.Kind.DECLARE,MATCHES_DECLARE);
    back.getTargets().add(sourceHandle);
  }
}
Program: 9583
Project: 9583
Buggy source:
private void doDeclareParents(DeclareParents declareParents,SourceTypeBinding sourceType){
  List newParents=declareParents.findMatchingNewParents(factory.fromEclipse(sourceType));
  if (!newParents.isEmpty()) {
    for (Iterator i=newParents.iterator(); i.hasNext(); ) {
      ResolvedTypeX parent=(ResolvedTypeX)i.next();
      addParent(sourceType,parent);
    }
  }
}

Fixed version (ground truth):
private void doDeclareParents(DeclareParents declareParents,SourceTypeBinding sourceType){
  List newParents=declareParents.findMatchingNewParents(factory.fromEclipse(sourceType));
  if (!newParents.isEmpty()) {
    for (Iterator i=newParents.iterator(); i.hasNext(); ) {
      ResolvedTypeX parent=(ResolvedTypeX)i.next();
      if (dangerousInterfaces.containsKey(parent)) {
        ResolvedTypeX onType=factory.fromEclipse(sourceType);
        factory.showMessage(IMessage.ERROR,onType + "String_Node_Str" + dangerousInterfaces.get(parent),onType.getSourceLocation(),null);
      }
      addParent(sourceType,parent);
    }
  }
}
Program: 9584
Project: 9584
Buggy source:
public static Test suite(){
  TestSuite suite=new TestSuite(AjdeTests.class.getName());
  suite.addTestSuite(BuildOptionsTest.class);
  suite.addTestSuite(BuildConfigurationTests.class);
  suite.addTestSuite(StructureModelRegressionTest.class);
  suite.addTestSuite(StructureModelTest.class);
  suite.addTestSuite(VersionTest.class);
  suite.addTestSuite(CompilerMessagesTest.class);
  suite.addTestSuite(AsmDeclarationsTest.class);
  suite.addTestSuite(AsmRelationshipsTest.class);
  suite.addTestSuite(ResourceCopyTestCase.class);
  return suite;
}

Fixed version (ground truth):
public static Test suite(){
  TestSuite suite=new TestSuite(AjdeTests.class.getName());
  suite.addTestSuite(BuildOptionsTest.class);
  suite.addTestSuite(BuildConfigurationTests.class);
  suite.addTestSuite(StructureModelRegressionTest.class);
  suite.addTestSuite(StructureModelTest.class);
  suite.addTestSuite(VersionTest.class);
  suite.addTestSuite(CompilerMessagesTest.class);
  suite.addTestSuite(AsmDeclarationsTest.class);
  suite.addTestSuite(AsmRelationshipsTest.class);
  return suite;
}
Program: 9585
Project: 9585
Buggy source:
/** 
 * @todo	add negative test to make sure things that aren't runnable aren't annotated
 */
public void testMainClassNodeInfo() throws IOException {
  StructureModel model=Ajde.getDefault().getStructureModelManager().getStructureModel();
  assertTrue("String_Node_Str",model != null);
  assertTrue("String_Node_Str",model.getRoot() != null);
  File testFile=openFile("String_Node_Str");
  IProgramElement node=model.findNodeForSourceLine(testFile.getCanonicalPath(),11);
  assertTrue("String_Node_Str",node != null);
  System.err.println("String_Node_Str" + node);
  IProgramElement pNode=(IProgramElement)((IProgramElement)node).getParent();
  if (null == pNode) {
    assertTrue("String_Node_Str" + node,false);
  }
  assertTrue("String_Node_Str" + pNode.getName(),pNode.isRunnable());
}

Fixed version (ground truth):
/** 
 * @todo	add negative test to make sure things that aren't runnable aren't annotated
 */
public void testMainClassNodeInfo() throws IOException {
  StructureModel model=Ajde.getDefault().getStructureModelManager().getStructureModel();
  assertTrue("String_Node_Str",model != null);
  assertTrue("String_Node_Str",model.getRoot() != null);
  File testFile=openFile("String_Node_Str");
  IProgramElement node=model.findNodeForSourceLine(testFile.getCanonicalPath(),11);
  assertTrue("String_Node_Str",node != null);
  IProgramElement pNode=(IProgramElement)((IProgramElement)node).getParent();
  if (null == pNode) {
    assertTrue("String_Node_Str" + node,false);
  }
  assertTrue("String_Node_Str" + pNode.getName(),pNode.isRunnable());
}
Program: 9586
Project: 9586
Buggy source:
/** 
 * Use to create program element nodes that correspond to source locations.
 */
public ProgramElement(String name,Kind kind,List modifiers,Accessibility accessibility,String declaringType,String packageName,String formalComment,ISourceLocation sourceLocation,List relations,List children,boolean member){
  this(name,kind,children);
  this.sourceLocation=sourceLocation;
  this.kind=kind;
  this.modifiers=modifiers;
  this.accessibility=accessibility;
  this.declaringType=declaringType;
  this.packageName=packageName;
  this.formalComment=formalComment;
  this.relations=relations;
}

Fixed version (ground truth):
/** 
 * Use to create program element nodes that correspond to source locations.
 */
public ProgramElement(String name,Kind kind,int modifiers,Accessibility accessibility,String declaringType,String packageName,String formalComment,ISourceLocation sourceLocation,List relations,List children,boolean member){
  this(name,kind,children);
  this.sourceLocation=sourceLocation;
  this.kind=kind;
  this.modifiers=genModifiers(modifiers);
  this.accessibility=accessibility;
  this.declaringType=declaringType;
  this.packageName=packageName;
  this.formalComment=formalComment;
  this.relations=relations;
}
Program: 9587
Project: 9587
Buggy source:
public static List genModifiers(int modifiers){
  List modifiersList=new ArrayList();
  if ((modifiers & AccStatic) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccFinal) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccSynchronized) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccVolatile) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccTransient) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccNative) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccAbstract) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  return modifiersList;
}

Fixed version (ground truth):
private static List genModifiers(int modifiers){
  List modifiersList=new ArrayList();
  if ((modifiers & AccStatic) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccFinal) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccSynchronized) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccVolatile) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccTransient) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccNative) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  if ((modifiers & AccAbstract) != 0)   modifiersList.add(IProgramElement.Modifiers.STATIC);
  return modifiersList;
}
Program: 9588
Project: 9588
Buggy source:
public EclipseTypeMunger build(ClassScope classScope){
  EclipseFactory world=EclipseFactory.fromScopeLookupEnvironment(classScope);
  binding=classScope.referenceContext.binding.resolveTypesFor(binding);
  resolveOnType(classScope);
  if (ignoreFurtherInvestigation)   return null;
  if (onTypeBinding.isInterface()) {
    ignoreFurtherInvestigation=true;
    return null;
  }
  if (onTypeBinding.isNestedType()) {
    classScope.problemReporter().signalError(sourceStart,sourceEnd,"String_Node_Str");
    ignoreFurtherInvestigation=true;
    return null;
  }
  ResolvedTypeX declaringTypeX=world.fromEclipse(onTypeBinding);
  ResolvedTypeX aspectType=world.fromEclipse(classScope.referenceContext.binding);
  ResolvedMember bindingAsMember=world.makeResolvedMember(binding);
  ResolvedMember signature=new ResolvedMember(Member.CONSTRUCTOR,declaringTypeX,declaredModifiers,ResolvedTypeX.VOID,"String_Node_Str",bindingAsMember.getParameterTypes());
  signature.setCheckedExceptions(world.fromEclipse(binding.thrownExceptions));
  ResolvedMember syntheticInterMember=AjcMemberMaker.interConstructor(declaringTypeX,signature,aspectType);
  NewConstructorTypeMunger myMunger=new NewConstructorTypeMunger(signature,syntheticInterMember,null,null);
  setMunger(myMunger);
  myMunger.check(world.getWorld());
  this.selector=binding.selector=NameMangler.postIntroducedConstructor(EclipseFactory.fromBinding(binding.declaringClass),declaringTypeX).toCharArray();
  return new EclipseTypeMunger(world,myMunger,aspectType,this);
}

Fixed version (ground truth):
public EclipseTypeMunger build(ClassScope classScope){
  EclipseFactory world=EclipseFactory.fromScopeLookupEnvironment(classScope);
  binding=classScope.referenceContext.binding.resolveTypesFor(binding);
  resolveOnType(classScope);
  if (ignoreFurtherInvestigation)   return null;
  if (onTypeBinding.isInterface()) {
    ignoreFurtherInvestigation=true;
    return null;
  }
  if (onTypeBinding.isNestedType()) {
    classScope.problemReporter().signalError(sourceStart,sourceEnd,"String_Node_Str");
    ignoreFurtherInvestigation=true;
    return null;
  }
  ResolvedTypeX declaringTypeX=world.fromEclipse(onTypeBinding);
  ResolvedTypeX aspectType=world.fromEclipse(classScope.referenceContext.binding);
  ResolvedMember bindingAsMember=world.makeResolvedMember(binding);
  ResolvedMember signature=new ResolvedMember(Member.CONSTRUCTOR,declaringTypeX,declaredModifiers,ResolvedTypeX.VOID,"String_Node_Str",bindingAsMember.getParameterTypes(),world.fromEclipse(binding.thrownExceptions));
  ResolvedMember syntheticInterMember=AjcMemberMaker.interConstructor(declaringTypeX,signature,aspectType);
  NewConstructorTypeMunger myMunger=new NewConstructorTypeMunger(signature,syntheticInterMember,null,null);
  setMunger(myMunger);
  myMunger.check(world.getWorld());
  this.selector=binding.selector=NameMangler.postIntroducedConstructor(EclipseFactory.fromBinding(binding.declaringClass),declaringTypeX).toCharArray();
  return new EclipseTypeMunger(world,myMunger,aspectType,this);
}