nus-yam/ex-repair huggingface dataset:
Program: 84620
Project: 84620
Buggy source:
@Override public void resolveTypes(MarkerList markers,IContext context,boolean using){
  if (this.parent != null) {
    this.parent.resolveTypes(markers,context,false);
    context=this.parent.getContext();
  }
  if (using) {
    if (!(context instanceof IClass)) {
      markers.add(this.position,"String_Node_Str");
      return;
    }
    IClassBody body=((IClass)context).getBody();
    IDataMember field=body.getField(this.name);
    if (field != null) {
      this.field=field;
      return;
    }
    this.methods=new ArrayList();
    int len=body.methodCount();
    for (int i=0; i < len; i++) {
      IMethod m=body.getMethod(i);
      if (m.getName() == this.name) {
        this.methods.add(m);
      }
    }
    if (!this.methods.isEmpty()) {
      return;
    }
    markers.add(this.position,"String_Node_Str",this.name.qualified);
    return;
  }
  Package pack=context.resolvePackage(this.name);
  if (pack != null) {
    this.thePackage=pack;
    return;
  }
  IClass iclass=context.resolveClass(this.name);
  if (iclass != null) {
    this.theClass=iclass;
    return;
  }
  markers.add(this.position,"String_Node_Str",this.name.qualified);
}

Fixed version (ground truth):
@Override public void resolveTypes(MarkerList markers,IContext context,boolean using){
  if (this.parent != null) {
    this.parent.resolveTypes(markers,context,false);
    context=this.parent.getContext();
    if (context == null) {
      return;
    }
  }
  if (using) {
    if (!(context instanceof IClass)) {
      markers.add(this.position,"String_Node_Str");
      return;
    }
    IClassBody body=((IClass)context).getBody();
    IDataMember field=body.getField(this.name);
    if (field != null) {
      this.field=field;
      return;
    }
    this.methods=new ArrayList();
    int len=body.methodCount();
    for (int i=0; i < len; i++) {
      IMethod m=body.getMethod(i);
      if (m.getName() == this.name) {
        this.methods.add(m);
      }
    }
    if (!this.methods.isEmpty()) {
      return;
    }
    markers.add(this.position,"String_Node_Str",this.name.qualified);
    return;
  }
  Package pack=context.resolvePackage(this.name);
  if (pack != null) {
    this.thePackage=pack;
    return;
  }
  IClass iclass=context.resolveClass(this.name);
  if (iclass != null) {
    this.theClass=iclass;
    return;
  }
  markers.add(this.position,"String_Node_Str",this.name.qualified);
}
Program: 84621
Project: 84621
Buggy source:
@Override public IType resolveType(Name name){
  ITypeAlias typeAlias=this.typeAliases.get(name);
  if (typeAlias != null) {
    return typeAlias.getType();
  }
  IClass iclass=this.resolveClass(name);
  if (iclass != null) {
    return new ClassType(iclass);
  }
  for (int i=0; i < this.includeCount; i++) {
    IType t=this.includes[i].getHeader().resolveType(name);
    if (t != null) {
      return t;
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public IType resolveType(Name name){
  ITypeAlias typeAlias=this.typeAliases.get(name);
  if (typeAlias != null) {
    return typeAlias.getType();
  }
  IClass iclass=this.resolveClass(name);
  if (iclass != null) {
    return new ClassType(iclass);
  }
  for (int i=0; i < this.includeCount; i++) {
    IType t=this.includes[i].resolveType(name);
    if (t != null) {
      return t;
    }
  }
  return null;
}
Program: 84622
Project: 84622
Buggy source:
@Override public IClass resolveClass(Name name){
  IClass iclass;
  for (int i=0; i < this.importCount; i++) {
    iclass=this.imports[i].resolveClass(name);
    if (iclass != null) {
      return iclass;
    }
  }
  for (int i=0; i < this.includeCount; i++) {
    iclass=this.includes[i].getHeader().resolveClass(name);
    if (iclass != null) {
      return iclass;
    }
  }
  if (this.pack != null) {
    return this.pack.resolveClass(name);
  }
  return null;
}

Fixed version (ground truth):
@Override public IClass resolveClass(Name name){
  IClass iclass;
  for (int i=0; i < this.importCount; i++) {
    iclass=this.imports[i].resolveClass(name);
    if (iclass != null) {
      return iclass;
    }
  }
  for (int i=0; i < this.includeCount; i++) {
    iclass=this.includes[i].resolveClass(name);
    if (iclass != null) {
      return iclass;
    }
  }
  if (this.pack != null) {
    return this.pack.resolveClass(name);
  }
  return null;
}
Program: 84623
Project: 84623
Buggy source:
@Override public IDataMember resolveField(Name name){
  for (int i=0; i < this.usingCount; i++) {
    IDataMember field=this.usings[i].resolveField(name);
    if (field != null) {
      return field;
    }
  }
  for (int i=0; i < this.includeCount; i++) {
    IDataMember field=this.includes[i].getHeader().resolveField(name);
    if (field != null) {
      return field;
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public IDataMember resolveField(Name name){
  for (int i=0; i < this.usingCount; i++) {
    IDataMember field=this.usings[i].resolveField(name);
    if (field != null) {
      return field;
    }
  }
  for (int i=0; i < this.includeCount; i++) {
    IDataMember field=this.includes[i].resolveField(name);
    if (field != null) {
      return field;
    }
  }
  return null;
}
Program: 84624
Project: 84624
Buggy source:
@Override public void getMethodMatches(List<MethodMatch> list,IValue instance,Name name,IArguments arguments){
  for (int i=0; i < this.usingCount; i++) {
    this.usings[i].getMethodMatches(list,instance,name,arguments);
  }
  for (int i=0; i < this.includeCount; i++) {
    this.includes[i].getHeader().getMethodMatches(list,instance,name,arguments);
  }
}

Fixed version (ground truth):
@Override public void getMethodMatches(List<MethodMatch> list,IValue instance,Name name,IArguments arguments){
  for (int i=0; i < this.usingCount; i++) {
    this.usings[i].getMethodMatches(list,instance,name,arguments);
  }
  for (int i=0; i < this.includeCount; i++) {
    this.includes[i].getMethodMatches(list,instance,name,arguments);
  }
}
Program: 84625
Project: 84625
Buggy source:
public final void parse(MarkerList markers,TokenIterator tokens){
  this.tokens=tokens;
  IToken token=null;
  while (true) {
    if (this.reparse) {
      this.reparse=false;
    }
 else {
      token=tokens.next();
      if (token == null) {
        break;
      }
    }
    if (this.skip > 0) {
      this.skip--;
      continue;
    }
    try {
      this.parser.parse(this,token);
    }
 catch (    SyntaxError ex) {
{
        if (ex.reparse) {
          this.reparse=true;
        }
        markers.add(ex);
      }
    }
catch (    Exception ex) {
{
        DyvilCompiler.logger.throwing("String_Node_Str","String_Node_Str",ex);
        markers.add(new SyntaxError(token,"String_Node_Str" + token + "String_Node_Str"+ ex.getMessage()));
      }
    }
    if (this.parser == null) {
      break;
    }
    if (DyvilCompiler.parseStack) {
      System.out.println(token + "String_Node_Str" + this.parser.name+ "String_Node_Str"+ this.parser.mode);
    }
  }
}

Fixed version (ground truth):
public final void parse(MarkerList markers,TokenIterator tokens){
  tokens.reset();
  this.tokens=tokens;
  IToken token=null;
  while (true) {
    if (this.reparse) {
      this.reparse=false;
    }
 else {
      token=tokens.next();
      if (token == null) {
        break;
      }
    }
    if (this.skip > 0) {
      this.skip--;
      continue;
    }
    try {
      this.parser.parse(this,token);
    }
 catch (    SyntaxError ex) {
{
        if (ex.reparse) {
          this.reparse=true;
        }
        markers.add(ex);
      }
    }
catch (    Exception ex) {
{
        DyvilCompiler.logger.throwing("String_Node_Str","String_Node_Str",ex);
        markers.add(new SyntaxError(token,"String_Node_Str" + token + "String_Node_Str"+ ex.getMessage()));
      }
    }
    if (this.parser == null) {
      break;
    }
    if (DyvilCompiler.parseStack) {
      System.out.println(token + "String_Node_Str" + this.parser.name+ "String_Node_Str"+ this.parser.mode);
    }
  }
}
Program: 84626
Project: 84626
Buggy source:
@Override public void reset(){
  this.mode=PACKAGE | IMPORT;
}

Fixed version (ground truth):
@Override public void reset(){
  this.mode=PACKAGE;
}
Program: 84627
Project: 84627
Buggy source:
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  if (token.type() == Symbols.SEMICOLON) {
    return;
  }
  if (this.isInMode(PACKAGE)) {
    if (this.parsePackage(pm,token)) {
      this.mode=IMPORT;
      return;
    }
  }
  if (this.isInMode(IMPORT)) {
    if (this.parseImport(pm,token)) {
      return;
    }
  }
  throw new SyntaxError(token,"String_Node_Str");
}

Fixed version (ground truth):
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  if (token.type() == Symbols.SEMICOLON) {
    return;
  }
switch (this.mode) {
case PACKAGE:
    if (this.parsePackage(pm,token)) {
      this.mode=IMPORT;
      return;
    }
case IMPORT:
  if (this.parseImport(pm,token)) {
    return;
  }
}
throw new SyntaxError(token,"String_Node_Str" + token + "String_Node_Str");
}
Program: 84628
Project: 84628
Buggy source:
public DyvilHeaderParser(IDyvilHeader unit){
  this.unit=unit;
  this.mode=PACKAGE | IMPORT;
}

Fixed version (ground truth):
public DyvilHeaderParser(IDyvilHeader unit){
  this.unit=unit;
  this.mode=PACKAGE;
}
Program: 84629
Project: 84629
Buggy source:
public DyvilUnitParser(IDyvilHeader unit){
  super(unit);
  this.mode=PACKAGE | IMPORT | CLASS;
}

Fixed version (ground truth):
public DyvilUnitParser(IDyvilHeader unit){
  super(unit);
  this.mode=PACKAGE;
}
Program: 84630
Project: 84630
Buggy source:
@Override public void reset(){
  this.mode=PACKAGE | IMPORT | CLASS;
}

Fixed version (ground truth):
@Override public void reset(){
  this.mode=PACKAGE;
}
Program: 84631
Project: 84631
Buggy source:
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  int type=token.type();
  if (this.isInMode(PACKAGE)) {
    if (this.parsePackage(pm,token)) {
      this.mode=IMPORT | CLASS;
      return;
    }
  }
  if (this.isInMode(IMPORT)) {
    if (this.parseImport(pm,token)) {
      this.mode=IMPORT | CLASS;
      return;
    }
  }
  if (this.isInMode(CLASS)) {
    if (type == Symbols.SEMICOLON) {
      return;
    }
    this.mode=CLASS;
    pm.pushParser(new ClassDeclarationParser(this.unit),true);
    return;
  }
  throw new SyntaxError(token,"String_Node_Str");
}

Fixed version (ground truth):
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  int type=token.type();
switch (this.mode) {
case PACKAGE:
    if (this.parsePackage(pm,token)) {
      this.mode=IMPORT;
      return;
    }
case IMPORT:
  if (this.parseImport(pm,token)) {
    this.mode=IMPORT;
    return;
  }
case CLASS:
if (type == Symbols.SEMICOLON) {
  return;
}
this.mode=CLASS;
pm.pushParser(new ClassDeclarationParser(this.unit),true);
return;
}
throw new SyntaxError(token,"String_Node_Str");
}
Program: 84634
Project: 84634
Buggy source:
public void findUnits(File source,File output,Package pack){
  if (source.isDirectory()) {
    String name=source.getName();
    for (    String s : source.list()) {
      this.findUnits(new CodeFile(source,s),new File(output,s),pack == null ? Package.rootPackage : pack.createSubPackage(name));
    }
    return;
  }
  String fileName=source.getPath();
  if (!DyvilCompiler.config.compileFile(fileName)) {
    return;
  }
  if (fileName.endsWith("String_Node_Str") || fileName.endsWith("String_Node_Str")) {
    return;
  }
  this.files.add(output);
  String extension=fileName.substring(fileName.lastIndexOf('.') + 1);
  IFileType fileType=FileTypes.fileTypes.get(extension);
  if (fileType == null) {
    return;
  }
  ICompilationUnit unit=fileType.createUnit(pack,(CodeFile)source,output);
  if (unit == null) {
    return;
  }
  if (unit.isHeader()) {
    this.units.insert(0,unit);
  }
 else {
    this.units.add(unit);
  }
}

Fixed version (ground truth):
public void findUnits(File source,File output,Package pack){
  if (source.isDirectory()) {
    for (    String s : source.list()) {
      this.findUnits(new CodeFile(source,s),new File(output,s),pack.createSubPackage(s));
    }
    return;
  }
  String fileName=source.getPath();
  if (!DyvilCompiler.config.isExcluded(fileName)) {
    return;
  }
  if (fileName.endsWith("String_Node_Str") || fileName.endsWith("String_Node_Str")) {
    return;
  }
  this.files.add(output);
  String extension=fileName.substring(fileName.lastIndexOf('.') + 1);
  IFileType fileType=FileTypes.fileTypes.get(extension);
  if (fileType == null) {
    return;
  }
  ICompilationUnit unit=fileType.createUnit(pack,(CodeFile)source,output);
  if (unit == null) {
    return;
  }
  if (unit.isHeader()) {
    this.units.insert(0,unit);
  }
 else {
    this.units.add(unit);
  }
}
Program: 84635
Project: 84635
Buggy source:
public static boolean isTerminator2(int type){
  return type == Symbols.DOT || type == Symbols.COMMA || type == Symbols.SEMICOLON || type == Symbols.EQUALS || type == Keywords.IS || type == Keywords.AS || (type & Symbols.CLOSE_BRACKET) == Symbols.CLOSE_BRACKET || type == Symbols.OPEN_SQUARE_BRACKET || type == Tokens.STRING_PART || type == Tokens.STRING_END;
}

Fixed version (ground truth):
public static boolean isTerminator2(int type){
  return type == Symbols.DOT || type == Symbols.COMMA || type == Symbols.SEMICOLON || type == Symbols.COLON || type == Symbols.EQUALS || type == Keywords.IS || type == Keywords.AS || (type & Symbols.CLOSE_BRACKET) == Symbols.CLOSE_BRACKET || type == Symbols.OPEN_SQUARE_BRACKET || type == Tokens.STRING_PART || type == Tokens.STRING_END;
}
Program: 84636
Project: 84636
Buggy source:
public static boolean isTerminator(int type){
  return type == Symbols.COMMA || type == Symbols.SEMICOLON || (type & Symbols.CLOSE_BRACKET) == Symbols.CLOSE_BRACKET;
}

Fixed version (ground truth):
public static boolean isTerminator(int type){
  return type == Symbols.COMMA || type == Symbols.SEMICOLON || type == Symbols.COLON || (type & Symbols.CLOSE_BRACKET) == Symbols.CLOSE_BRACKET;
}
Program: 84637
Project: 84637
Buggy source:
private boolean computeVariable(REPLVariable field){
  this.getClassName();
  MarkerList markers=new MarkerList();
  field.resolveTypes(markers,this);
  field.resolve(markers,this);
  field.checkTypes(markers,this);
  field.check(markers,this);
  if (this.reportErrors(markers)) {
    this.cleanup();
    return false;
  }
  field.cleanup(this,this);
  this.compileVariable(field);
  return true;
}

Fixed version (ground truth):
private boolean computeVariable(REPLVariable field){
  MarkerList markers=new MarkerList();
  field.resolveTypes(markers,this);
  field.resolve(markers,this);
  field.checkTypes(markers,this);
  field.check(markers,this);
  if (this.reportErrors(markers)) {
    this.cleanup();
    return false;
  }
  field.cleanup(this,this);
  this.compileVariable(field);
  return true;
}
Program: 84638
Project: 84638
Buggy source:
private void compileVariable(REPLVariable field){
  field.foldConstants();
  this.compileInnerClasses();
  field.compute(this.currentClassName);
  this.cleanup();
}

Fixed version (ground truth):
private void compileVariable(REPLVariable field){
  field.foldConstants();
  this.compileInnerClasses();
  field.compute();
  this.cleanup();
}
Program: 84639
Project: 84639
Buggy source:
@Override public void addField(IField field){
  this.getClassName();
  REPLVariable var=new REPLVariable(field.getPosition(),field.getName(),field.getType(),field.getValue());
  var.setAnnotations(field.getAnnotations(),field.annotationCount());
  var.modifiers=field.getModifiers();
  if (this.computeVariable(var)) {
    this.variables.put(var.name,var);
    System.out.println(var.toString());
  }
}

Fixed version (ground truth):
@Override public void addField(IField field){
  String className=this.getClassName();
  REPLVariable var=new REPLVariable(field.getPosition(),field.getName(),field.getType(),field.getValue(),className);
  var.setAnnotations(field.getAnnotations(),field.annotationCount());
  var.modifiers=field.getModifiers();
  if (this.computeVariable(var)) {
    this.variables.put(var.name,var);
    System.out.println(var.toString());
  }
}
Program: 84640
Project: 84640
Buggy source:
@Override public void setValue(IValue value){
  Name name=Name.getQualified("String_Node_Str" + resultIndex);
  this.getClassName();
  MarkerList markers=new MarkerList();
  value.resolveTypes(markers,this);
  value=value.resolve(markers,this);
  IType type=value.getType();
  IValue value1=value.withType(type,type,markers,this);
  if (value1 == null) {
  }
 else {
    value=value1;
    type=value1.getType();
  }
  value.checkTypes(markers,this);
  value.check(markers,this);
  if (this.reportErrors(markers)) {
    this.cleanup();
    return;
  }
  value=value.cleanup(this,this);
  REPLVariable field=new REPLVariable(CODE_POSITION,name,type,value);
  field.modifiers=Modifiers.FINAL;
  this.compileVariable(field);
  if (type != Types.VOID) {
    this.variables.put(field.name,field);
    System.out.println(field.toString());
    resultIndex++;
  }
}

Fixed version (ground truth):
@Override public void setValue(IValue value){
  Name name=Name.getQualified("String_Node_Str" + resultIndex);
  String className=this.getClassName();
  MarkerList markers=new MarkerList();
  value.resolveTypes(markers,this);
  value=value.resolve(markers,this);
  IType type=value.getType();
  IValue value1=value.withType(type,type,markers,this);
  if (value1 == null) {
  }
 else {
    value=value1;
    type=value1.getType();
  }
  value.checkTypes(markers,this);
  value.check(markers,this);
  if (this.reportErrors(markers)) {
    this.cleanup();
    return;
  }
  value=value.cleanup(this,this);
  REPLVariable field=new REPLVariable(CODE_POSITION,name,type,value,className);
  field.modifiers=Modifiers.FINAL;
  this.compileVariable(field);
  if (type != Types.VOID) {
    this.variables.put(field.name,field);
    System.out.println(field.toString());
    resultIndex++;
  }
}
Program: 84641
Project: 84641
Buggy source:
protected void compute(String className){
  List<IClassCompilable> compilableList=DyvilREPL.context.compilableList;
  if (this.className != null || (this.isConstant() && !compilableList.isEmpty())) {
    return;
  }
  try {
    this.className=className;
    Class c=this.generateClass(this.className,compilableList);
    if (this.type != Types.VOID) {
      java.lang.reflect.Field[] fields=c.getDeclaredFields();
      Object result=fields[0].get(null);
      IValue v=IValue.fromObject(result);
      if (v != null) {
        this.value=v;
      }
 else {
        this.value=new REPLResult(result);
      }
    }
 else {
      ReflectUtils.unsafe.ensureClassInitialized(c);
    }
  }
 catch (  ExceptionInInitializerError t) {
    Throwable ex=t.getCause();
    System.err.println(ex.getClass().getCanonicalName() + "String_Node_Str" + ex.getMessage());
    StackTraceElement[] trace=ex.getStackTrace();
    int len=trace.length - 10;
    for (int i=0; i < len; i++) {
      System.err.println("String_Node_Str" + trace[i]);
    }
    this.value=this.type.getDefaultValue();
  }
catch (  Throwable t) {
    t.printStackTrace();
  }
}

Fixed version (ground truth):
protected void compute(){
  List<IClassCompilable> compilableList=DyvilREPL.context.compilableList;
  if (this.isConstant() && !compilableList.isEmpty()) {
    return;
  }
  try {
    Class c=this.generateClass(this.className,compilableList);
    if (this.type != Types.VOID) {
      java.lang.reflect.Field[] fields=c.getDeclaredFields();
      Object result=fields[0].get(null);
      IValue v=IValue.fromObject(result);
      if (v != null) {
        this.value=v;
      }
 else {
        this.value=new REPLResult(result);
      }
    }
 else {
      ReflectUtils.unsafe.ensureClassInitialized(c);
    }
  }
 catch (  ExceptionInInitializerError t) {
    Throwable ex=t.getCause();
    System.err.println(ex.getClass().getCanonicalName() + "String_Node_Str" + ex.getMessage());
    StackTraceElement[] trace=ex.getStackTrace();
    int len=trace.length - 10;
    for (int i=0; i < len; i++) {
      System.err.println("String_Node_Str" + trace[i]);
    }
    this.value=this.type.getDefaultValue();
  }
catch (  Throwable t) {
    t.printStackTrace();
  }
}
Program: 84642
Project: 84642
Buggy source:
@Override public void writeSet(MethodWriter writer,IValue instance,IValue value) throws BytecodeException {
  if (this.className == null) {
    writer.writeInsn(Opcodes.AUTO_POP);
    return;
  }
  String extended=this.type.getExtendedName();
  writer.writeFieldInsn(Opcodes.PUTSTATIC,this.className,"String_Node_Str",extended);
}

Fixed version (ground truth):
@Override public void writeSet(MethodWriter writer,IValue instance,IValue value) throws BytecodeException {
  if (this.className == null) {
    writer.writeInsn(Opcodes.AUTO_POP);
    return;
  }
  String extended=this.type.getExtendedName();
  writer.writeFieldInsn(Opcodes.PUTSTATIC,this.className,this.name.qualified,extended);
}
Program: 84643
Project: 84643
Buggy source:
public REPLVariable(ICodePosition position,Name name,IType type,IValue value){
  super(null,name,type);
  this.position=position;
  this.value=value;
}

Fixed version (ground truth):
public REPLVariable(ICodePosition position,Name name,IType type,IValue value,String className){
  super(null,name,type);
  this.className=className;
  this.theClass=new REPLMemberClass(Name.getQualified(className),this);
  this.position=position;
  this.value=value;
}
Program: 84644
Project: 84644
Buggy source:
private Class generateClass(String className,List<IClassCompilable> compilableList) throws Throwable {
  String extendedType=type.getExtendedName();
  ClassWriter writer=new ClassWriter();
  writer.visit(DyvilCompiler.classVersion,Modifiers.PUBLIC | Modifiers.FINAL | ClassFormat.ACC_SUPER,className,null,"String_Node_Str",null);
  if (type != Types.VOID) {
    writer.visitField(this.modifiers | Modifiers.PUBLIC | Modifiers.STATIC| Modifiers.SYNTHETIC,"String_Node_Str",extendedType,null,null);
  }
  for (  IClassCompilable c : compilableList) {
    c.write(writer);
  }
  MethodWriter mw=new MethodWriterImpl(writer,writer.visitMethod(Modifiers.STATIC | Modifiers.SYNTHETIC,"String_Node_Str","String_Node_Str",null,null));
  mw.begin();
  for (  IClassCompilable c : compilableList) {
    c.writeStaticInit(mw);
  }
  if (type != Types.VOID) {
    value.writeExpression(mw);
    mw.writeFieldInsn(Opcodes.PUTSTATIC,className,"String_Node_Str",extendedType);
  }
 else {
    value.writeStatement(mw);
  }
  mw.writeInsn(Opcodes.RETURN);
  mw.end();
  writer.visitEnd();
  byte[] bytes=writer.toByteArray();
  if (type != Types.VOID || !compilableList.isEmpty()) {
    return REPLMemberClass.loadClass(className,bytes);
  }
  return ReflectUtils.unsafe.defineAnonymousClass(REPLVariable.class,bytes,null);
}

Fixed version (ground truth):
private Class generateClass(String className,List<IClassCompilable> compilableList) throws Throwable {
  String name=this.name.qualified;
  String extendedType=type.getExtendedName();
  ClassWriter writer=new ClassWriter();
  writer.visit(DyvilCompiler.classVersion,Modifiers.PUBLIC | Modifiers.FINAL | ClassFormat.ACC_SUPER,className,null,"String_Node_Str",null);
  if (type != Types.VOID) {
    writer.visitField(this.modifiers | Modifiers.PUBLIC | Modifiers.STATIC| Modifiers.SYNTHETIC,name,extendedType,null,null);
  }
  for (  IClassCompilable c : compilableList) {
    c.write(writer);
  }
  MethodWriter mw=new MethodWriterImpl(writer,writer.visitMethod(Modifiers.STATIC | Modifiers.SYNTHETIC,"String_Node_Str","String_Node_Str",null,null));
  mw.begin();
  for (  IClassCompilable c : compilableList) {
    c.writeStaticInit(mw);
  }
  if (type != Types.VOID) {
    value.writeExpression(mw);
    mw.writeFieldInsn(Opcodes.PUTSTATIC,className,name,extendedType);
  }
 else {
    value.writeStatement(mw);
  }
  mw.writeInsn(Opcodes.RETURN);
  mw.end();
  writer.visitEnd();
  byte[] bytes=writer.toByteArray();
  if (type != Types.VOID || !compilableList.isEmpty()) {
    return REPLMemberClass.loadClass(className,bytes);
  }
  return ReflectUtils.unsafe.defineAnonymousClass(REPLVariable.class,bytes,null);
}
Program: 84645
Project: 84645
Buggy source:
@Override public void writeGet(MethodWriter writer,IValue instance) throws BytecodeException {
  if (this.isConstant()) {
    this.value.writeExpression(writer);
    return;
  }
  if (this.className == null) {
    this.type.writeDefaultValue(writer);
    return;
  }
  String extended=this.type.getExtendedName();
  writer.writeFieldInsn(Opcodes.GETSTATIC,this.className,"String_Node_Str",extended);
}

Fixed version (ground truth):
@Override public void writeGet(MethodWriter writer,IValue instance) throws BytecodeException {
  if (this.isConstant()) {
    this.value.writeExpression(writer);
    return;
  }
  if (this.className == null) {
    this.type.writeDefaultValue(writer);
    return;
  }
  String extended=this.type.getExtendedName();
  writer.writeFieldInsn(Opcodes.GETSTATIC,this.className,this.name.qualified,extended);
}
Program: 84646
Project: 84646
Buggy source:
@Override public boolean add(E element){
  return this.map.put(element,VALUE) != null;
}

Fixed version (ground truth):
@Override public boolean add(E element){
  return this.map.put(element,VALUE) == null;
}
Program: 84647
Project: 84647
Buggy source:
@Override public IValue resolve(MarkerList markers,IContext context){
  this.arguments.resolve(markers,context);
  if (this.type == null || !this.type.isResolved()) {
    return this;
  }
  if (this.type.isArrayType()) {
    int len=this.arguments.size();
    int dims=this.type.getArrayDimensions();
    if (dims != len) {
      Marker marker=markers.create(this.position,"String_Node_Str");
      marker.addInfo("String_Node_Str" + dims);
      marker.addInfo("String_Node_Str" + len);
      return this;
    }
    if (!(this.arguments instanceof ArgumentList)) {
      markers.add(markers.create(this.position,"String_Node_Str"));
      return this;
    }
    ArgumentList paramList=(ArgumentList)this.arguments;
    for (int i=0; i < len; i++) {
      IValue v=paramList.getValue(i);
      IType t=v.getType();
      if (t != Types.INT) {
        Marker marker=markers.create(v.getPosition(),"String_Node_Str");
        marker.addInfo("String_Node_Str" + t);
      }
    }
    return this;
  }
  IConstructor match=IContext.resolveConstructor(this.type,this.arguments);
  if (match == null) {
    Marker marker=markers.create(this.position,"String_Node_Str",this.type.toString());
    if (!this.arguments.isEmpty()) {
      StringBuilder builder=new StringBuilder("String_Node_Str");
      this.arguments.typesToString(builder);
      marker.addInfo(builder.toString());
    }
    return this;
  }
  this.constructor=match;
  return this;
}

Fixed version (ground truth):
@Override public IValue resolve(MarkerList markers,IContext context){
  this.arguments.resolve(markers,context);
  if (this.type == null || !this.type.isResolved()) {
    return this;
  }
  if (this.type.isArrayType()) {
    int len=this.arguments.size();
    int dims=this.type.getArrayDimensions();
    if (dims != len) {
      Marker marker=markers.create(this.position,"String_Node_Str");
      marker.addInfo("String_Node_Str" + dims);
      marker.addInfo("String_Node_Str" + len);
      return this;
    }
    if (!(this.arguments instanceof ArgumentList)) {
      markers.add(markers.create(this.position,"String_Node_Str"));
      return this;
    }
    ArgumentList paramList=(ArgumentList)this.arguments;
    for (int i=0; i < len; i++) {
      IValue v=paramList.getValue(i);
      IType t=v.getType();
      if (t != Types.INT) {
        Marker marker=markers.create(v.getPosition(),"String_Node_Str");
        marker.addInfo("String_Node_Str" + t);
      }
    }
    return this;
  }
  this.constructor=IContext.resolveConstructor(this.type,this.arguments);
  return this;
}
Program: 84648
Project: 84648
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  this.arguments.check(markers,context);
  if (this.type == null || this.type.isArrayType()) {
    return;
  }
  IClass iclass=this.type.getTheClass();
  if (iclass == null) {
    return;
  }
  if (iclass.hasModifier(Modifiers.INTERFACE_CLASS)) {
    markers.add(this.position,"String_Node_Str",iclass.getName());
  }
 else   if (iclass.hasModifier(Modifiers.ABSTRACT)) {
    markers.add(this.position,"String_Node_Str",iclass.getName());
  }
  if (this.constructor != null) {
    this.constructor.checkCall(markers,this.position,context,this.arguments);
  }
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  this.arguments.check(markers,context);
  if (this.type == null || this.type.isArrayType()) {
    return;
  }
  IClass iclass=this.type.getTheClass();
  if (iclass == null) {
    return;
  }
  if (iclass.hasModifier(Modifiers.INTERFACE_CLASS)) {
    markers.add(this.position,"String_Node_Str",this.type);
    return;
  }
  if (iclass.hasModifier(Modifiers.ABSTRACT)) {
    markers.add(this.position,"String_Node_Str",this.type);
  }
  if (this.constructor != null) {
    this.constructor.checkCall(markers,this.position,context,this.arguments);
  }
 else {
    Marker marker=markers.create(this.position,"String_Node_Str",this.type.toString());
    if (!this.arguments.isEmpty()) {
      StringBuilder builder=new StringBuilder("String_Node_Str");
      this.arguments.typesToString(builder);
      marker.addInfo(builder.toString());
    }
  }
}
Program: 84649
Project: 84649
Buggy source:
@Override public void writeExpression(MethodWriter writer) throws BytecodeException {
  this.field.writeGet(writer,this.instance);
  if (!this.type.isSuperTypeOf(this.field.getType())) {
    writer.writeTypeInsn(Opcodes.CHECKCAST,this.type.getInternalName());
  }
}

Fixed version (ground truth):
@Override public void writeExpression(MethodWriter writer) throws BytecodeException {
  this.field.writeGet(writer,this.instance);
  if (this.type != null && !this.type.isSuperTypeOf(this.field.getType())) {
    writer.writeTypeInsn(Opcodes.CHECKCAST,this.type.getInternalName());
  }
}
Program: 84650
Project: 84650
Buggy source:
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (type == Types.UNKNOWN || type == Types.VOID) {
    return this;
  }
  IValue value1=this.value.withType(type,typeContext,markers,context);
  if (value1 == null) {
    return null;
  }
  this.value=value1;
  return this;
}

Fixed version (ground truth):
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (type == Types.VOID) {
    return this;
  }
  IValue value1=this.value.withType(type,typeContext,markers,context);
  if (value1 == null) {
    return null;
  }
  this.value=value1;
  return this;
}
Program: 84651
Project: 84651
Buggy source:
@Override public boolean isType(IType type){
  return this.value == null ? type == Types.UNKNOWN || type == Types.VOID : this.value.isType(type);
}

Fixed version (ground truth):
@Override public boolean isType(IType type){
  return type == Types.VOID || this.value.isType(type);
}
Program: 84652
Project: 84652
Buggy source:
private AbstractCall resolveApply(MarkerList markers,IContext context){
  IValue instance;
  IMethod method;
  IDataMember field=context.resolveField(this.name);
  if (field == null) {
    IClass iclass=IContext.resolveClass(context,this.name);
    if (iclass == null) {
      return null;
    }
    IMethod match=IContext.resolveMethod(iclass,null,Name.apply,this.arguments);
    if (match == null) {
      return null;
    }
    method=match;
    instance=new ClassAccess(this.position,new ClassType(iclass));
  }
 else {
    FieldAccess access=new FieldAccess(this.position);
    access.field=field;
    access.name=this.name;
    access.dotless=this.dotless;
    IMethod match=IContext.resolveMethod(field.getType(),access,Name.apply,this.arguments);
    if (match == null) {
      return null;
    }
    method=match;
    instance=access;
  }
  ApplyMethodCall call=new ApplyMethodCall(this.position);
  call.method=method;
  call.instance=instance;
  call.arguments=this.arguments;
  call.genericData=this.genericData;
  return call;
}

Fixed version (ground truth):
private AbstractCall resolveApply(MarkerList markers,IContext context){
  IValue instance;
  IMethod method;
  IDataMember field=context.resolveField(this.name);
  if (field == null) {
    IType itype=IContext.resolveType(context,this.name);
    if (itype == null) {
      return null;
    }
    IMethod match=IContext.resolveMethod(itype,null,Name.apply,this.arguments);
    if (match == null) {
      return null;
    }
    method=match;
    instance=new ClassAccess(this.position,itype);
  }
 else {
    FieldAccess access=new FieldAccess(this.position);
    access.field=field;
    access.name=this.name;
    access.dotless=this.dotless;
    IMethod match=IContext.resolveMethod(field.getType(),access,Name.apply,this.arguments);
    if (match == null) {
      return null;
    }
    method=match;
    instance=access;
  }
  ApplyMethodCall call=new ApplyMethodCall(this.position);
  call.method=method;
  call.instance=instance;
  call.arguments=this.arguments;
  call.genericData=this.genericData;
  return call;
}
Program: 84654
Project: 84654
Buggy source:
@Override public void toString(String prefix,StringBuilder buffer){
  if (this.parameterCount == 0) {
    buffer.append(Formatting.Method.emptyParameters);
  }
 else   if (this.parameterCount == 1) {
    IParameter param=this.parameters[0];
    if (param.getType() != null) {
      buffer.append('(');
      param.toString(prefix,buffer);
      buffer.append(')');
    }
 else {
      buffer.append(param.getName());
    }
  }
 else {
    Util.astToString(prefix,this.parameters,this.parameterCount,Formatting.Method.parameterSeperator,buffer);
  }
  buffer.append(Formatting.Expression.lambdaSeperator);
  this.value.toString(prefix,buffer);
}

Fixed version (ground truth):
@Override public void toString(String prefix,StringBuilder buffer){
  if (this.parameterCount == 1) {
    IParameter param=this.parameters[0];
    if (param.getType() != null) {
      buffer.append('(');
      param.toString(prefix,buffer);
      buffer.append(')');
    }
 else {
      buffer.append(param.getName());
    }
    buffer.append(' ');
  }
 else   if (this.parameterCount > 1) {
    Util.astToString(prefix,this.parameters,this.parameterCount,Formatting.Method.parameterSeperator,buffer);
    buffer.append(' ');
  }
  buffer.append(Formatting.Expression.lambdaSeperator);
  this.value.toString(prefix,buffer);
}
Program: 84655
Project: 84655
Buggy source:
@Override public void toString(String prefix,StringBuilder buffer){
  if (this.parameterCount == 1) {
    this.parameterTypes[0].toString(prefix,buffer);
  }
 else {
    buffer.append(Formatting.Method.parametersStart);
    Util.astToString(prefix,this.parameterTypes,this.parameterCount,Formatting.Method.parameterSeperator,buffer);
    buffer.append(Formatting.Method.parametersEnd);
  }
  buffer.append(Formatting.Expression.lambdaSeperator);
  this.returnType.toString("String_Node_Str",buffer);
}

Fixed version (ground truth):
@Override public void toString(String prefix,StringBuilder buffer){
  if (this.parameterCount == 1) {
    this.parameterTypes[0].toString(prefix,buffer);
    buffer.append(' ');
  }
 else   if (this.parameterCount > 0) {
    buffer.append(Formatting.Method.parametersStart);
    Util.astToString(prefix,this.parameterTypes,this.parameterCount,Formatting.Method.parameterSeperator,buffer);
    buffer.append(Formatting.Method.parametersEnd);
    buffer.append(' ');
  }
  buffer.append(Formatting.Expression.lambdaSeperator);
  this.returnType.toString("String_Node_Str",buffer);
}
Program: 84656
Project: 84656
Buggy source:
@Override public boolean isResolved(){
  return false;
}

Fixed version (ground truth):
@Override public boolean isResolved(){
  return true;
}
Program: 84659
Project: 84659
Buggy source:
@Override public IType getConcreteType(ITypeContext context){
  TupleType tt=new TupleType(this.typeCount);
  for (int i=0; i < this.typeCount; i++) {
    tt.types[i]=this.types[i].getConcreteType(context);
  }
  return tt;
}

Fixed version (ground truth):
@Override public IType getConcreteType(ITypeContext context){
  TupleType tt=new TupleType(this.typeCount);
  tt.typeCount=this.typeCount;
  for (int i=0; i < this.typeCount; i++) {
    tt.types[i]=this.types[i].getConcreteType(context);
  }
  return tt;
}
Program: 84660
Project: 84660
Buggy source:
@Override public IType clone(){
  TupleType tt=new TupleType(this.typeCount);
  System.arraycopy(this.types,0,tt.types,0,this.typeCount);
  return tt;
}

Fixed version (ground truth):
@Override public IType clone(){
  TupleType tt=new TupleType(this.typeCount);
  tt.typeCount=this.typeCount;
  System.arraycopy(this.types,0,tt.types,0,this.typeCount);
  return tt;
}
Program: 84661
Project: 84661
Buggy source:
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount){
  outer:   for (int i=0; i < this.methodCount; i++) {
    IMethod m=this.methods[i];
    if (m.getName() != name) {
      continue;
    }
    if (parameterCount != m.parameterCount()) {
      continue;
    }
    for (int p=0; p < parameterCount; p++) {
      IType t1=parameters[p].getType();
      IType t2=m.getParameter(p).getType();
      if (!t1.equals(t2)) {
        continue outer;
      }
    }
    return m;
  }
  return null;
}

Fixed version (ground truth):
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount,IType concrete){
  outer:   for (int i=0; i < this.methodCount; i++) {
    IMethod m=this.methods[i];
    if (m.getName() != name) {
      continue;
    }
    if (parameterCount != m.parameterCount()) {
      continue;
    }
    for (int p=0; p < parameterCount; p++) {
      IType t1=parameters[p].getType();
      IType t2=m.getParameter(p).getType().getConcreteType(concrete);
      if (!t1.equals(t2)) {
        continue outer;
      }
    }
    return m;
  }
  return null;
}
Program: 84662
Project: 84662
Buggy source:
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount){
  if (this.body != null) {
    IMethod m=this.body.getMethod(name,parameters,parameterCount);
    if (m != null) {
      return m;
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount,IType concrete){
  if (this.body != null) {
    IMethod m=this.body.getMethod(name,parameters,parameterCount,concrete);
    if (m != null) {
      return m;
    }
  }
  return null;
}
Program: 84663
Project: 84663
Buggy source:
@Override public IMethod getSuperMethod(Name name,IParameter[] parameters,int parameterCount){
  if (this.superType != null) {
    IClass iclass=this.superType.getTheClass();
    if (iclass != null) {
      IMethod m=iclass.getMethod(name,parameters,parameterCount);
      if (m != null) {
        return m;
      }
    }
  }
  for (int i=0; i < this.interfaceCount; i++) {
    IClass iclass=this.interfaces[i].getTheClass();
    if (iclass != null) {
      IMethod m=iclass.getMethod(name,parameters,parameterCount);
      if (m != null) {
        return m;
      }
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public IMethod getSuperMethod(Name name,IParameter[] parameters,int parameterCount){
  if (this.superType != null) {
    IClass iclass=this.superType.getTheClass();
    if (iclass != null) {
      IMethod m=iclass.getMethod(name,parameters,parameterCount,this.superType);
      if (m != null) {
        return m;
      }
    }
  }
  for (int i=0; i < this.interfaceCount; i++) {
    IType type=this.interfaces[i];
    IClass iclass=type.getTheClass();
    if (iclass != null) {
      IMethod m=iclass.getMethod(name,parameters,parameterCount,type);
      if (m != null) {
        return m;
      }
    }
  }
  return null;
}
Program: 84665
Project: 84665
Buggy source:
public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount);

Fixed version (ground truth):
public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount,IType concrete);
Program: 84666
Project: 84666
Buggy source:
public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount);

Fixed version (ground truth):
public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount,IType concrete);
Program: 84667
Project: 84667
Buggy source:
@Override public void resolve(MarkerList markers,IContext context){
  super.resolve(markers,context);
  IClassBody body=this.theClass.getBody();
  if (body != null) {
    if (markers != null && body.constructorCount() > 0) {
      markers.add(this.theClass.getPosition(),"String_Node_Str",this.theClass.getName().qualified);
    }
    IField f=body.getField(Name.instance);
    if (f != null) {
      this.instanceField=f;
      return;
    }
  }
  Field f=new Field(this.theClass,Name.instance,this.theClass.getType());
  f.modifiers=Modifiers.PUBLIC | Modifiers.CONST | Modifiers.SYNTHETIC;
  this.instanceField=f;
  if (this.theClass.getMethod(Name.toString,null,0) != null) {
    this.hasToString=true;
  }
}

Fixed version (ground truth):
@Override public void resolve(MarkerList markers,IContext context){
  super.resolve(markers,context);
  IClassBody body=this.theClass.getBody();
  if (body != null) {
    if (markers != null && body.constructorCount() > 0) {
      markers.add(this.theClass.getPosition(),"String_Node_Str",this.theClass.getName().qualified);
    }
    IField f=body.getField(Name.instance);
    if (f != null) {
      this.instanceField=f;
      return;
    }
  }
  Field f=new Field(this.theClass,Name.instance,this.theClass.getType());
  f.modifiers=Modifiers.PUBLIC | Modifiers.CONST | Modifiers.SYNTHETIC;
  this.instanceField=f;
  if (this.theClass.getMethod(Name.toString,null,0,null) != null) {
    this.hasToString=true;
  }
}
Program: 84668
Project: 84668
Buggy source:
@Override public IType resolveType(ITypeVariable typeVar){
  if (typeVar.getGeneric().isMethod()) {
    return this.generics[typeVar.getIndex()];
  }
  return this.instanceType.resolveType(typeVar);
}

Fixed version (ground truth):
@Override public IType resolveType(ITypeVariable typeVar){
  int index=typeVar.getIndex();
  if (this.method.getTypeVariable(index) == typeVar) {
    return this.generics[index];
  }
  return this.instanceType.resolveType(typeVar);
}
Program: 84669
Project: 84669
Buggy source:
public GenericData(int count){
  this.generics=new IType[count];
  this.computedGenerics=count;
}

Fixed version (ground truth):
public GenericData(IMethod method,int count){
  this.method=method;
  this.generics=new IType[count];
  this.computedGenerics=count;
}
Program: 84670
Project: 84670
Buggy source:
@Override public void toString(String prefix,StringBuilder buffer){
  buffer.append(this.name);
  this.variance.appendPrefix(buffer);
  if (this.lowerBound != null) {
    buffer.append(Formatting.Type.genericLowerBound);
    this.lowerBound.toString(prefix,buffer);
  }
  if (this.upperBoundCount > 0) {
    buffer.append(Formatting.Type.genericUpperBound);
    this.upperBounds[0].toString(prefix,buffer);
    for (int i=1; i < this.upperBoundCount; i++) {
      buffer.append(Formatting.Type.genericBoundSeperator);
      this.upperBounds[i].toString(prefix,buffer);
    }
  }
}

Fixed version (ground truth):
@Override public void toString(String prefix,StringBuilder buffer){
  this.variance.appendPrefix(buffer);
  buffer.append(this.name);
  if (this.lowerBound != null) {
    buffer.append(Formatting.Type.genericLowerBound);
    this.lowerBound.toString(prefix,buffer);
  }
  if (this.upperBoundCount > 0) {
    buffer.append(Formatting.Type.genericUpperBound);
    this.upperBounds[0].toString(prefix,buffer);
    for (int i=1; i < this.upperBoundCount; i++) {
      buffer.append(Formatting.Type.genericBoundSeperator);
      this.upperBounds[i].toString(prefix,buffer);
    }
  }
}
Program: 84671
Project: 84671
Buggy source:
public PositionedTypeVarType(ICodePosition position,ITypeVariable typeVar){
  super(typeVar);
}

Fixed version (ground truth):
public PositionedTypeVarType(ICodePosition position,ITypeVariable typeVar){
  super(typeVar);
  this.position=position;
}
Program: 84672
Project: 84672
Buggy source:
@Override public IType resolve(MarkerList markers,IContext context,TypePosition position){
  if (this.bound != null) {
    this.bound=this.bound.resolve(markers,context,TypePosition.TYPE);
  }
  if (position != TypePosition.GENERIC_ARGUMENT) {
    markers.add(this.position,"String_Node_Str");
    return this.bound == null ? Types.ANY : this.bound;
  }
  return this;
}

Fixed version (ground truth):
@Override public IType resolve(MarkerList markers,IContext context,TypePosition position){
  if (this.bound != null) {
    this.bound=this.bound.resolve(markers,context,TypePosition.SUPER_TYPE_ARGUMENT);
  }
  if (position != TypePosition.GENERIC_ARGUMENT) {
    markers.add(this.position,"String_Node_Str");
    return this.bound == null ? Types.ANY : this.bound;
  }
  return this;
}
Program: 84673
Project: 84673
Buggy source:
@Override public GenericData getGenericData(GenericData genericData,IValue instance,IArguments arguments){
  if (!this.hasTypeVariables()) {
    return genericData;
  }
  if (genericData == null) {
    genericData=new GenericData(this.genericCount);
    if (instance != null) {
      genericData.instanceType=instance.getType();
    }
    this.inferTypes(genericData,instance,arguments);
    return genericData;
  }
  if (instance != null) {
    genericData.instanceType=instance.getType();
  }
  genericData.setTypeCount(this.genericCount);
  this.inferTypes(genericData,instance,arguments);
  return genericData;
}

Fixed version (ground truth):
@Override public GenericData getGenericData(GenericData genericData,IValue instance,IArguments arguments){
  if (!this.hasTypeVariables()) {
    return genericData;
  }
  if (genericData == null) {
    genericData=new GenericData(this,this.genericCount);
    if (instance != null) {
      genericData.instanceType=instance.getType();
    }
    this.inferTypes(genericData,instance,arguments);
    return genericData;
  }
  genericData.method=this;
  if (instance != null) {
    genericData.instanceType=instance.getType();
  }
  genericData.setTypeCount(this.genericCount);
  this.inferTypes(genericData,instance,arguments);
  return genericData;
}
Program: 84675
Project: 84675
Buggy source:
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount){
  return null;
}

Fixed version (ground truth):
@Override public IMethod getMethod(Name name,IParameter[] parameters,int parameterCount,IType concrete){
  return null;
}
Program: 84676
Project: 84676
Buggy source:
@Override public IType getReturnType(){
  if (this.variance == Variance.CONTRAVARIANT) {
    return Types.ANY;
  }
  return this.bound;
}

Fixed version (ground truth):
@Override public IType getReturnType(){
  if (this.bound == null || this.variance == Variance.CONTRAVARIANT) {
    return Types.ANY;
  }
  return this.bound;
}
Program: 84677
Project: 84677
Buggy source:
@Override public IValue resolve(MarkerList markers,IContext context){
  this.value1.resolve(markers,context);
  this.value2.resolve(markers,context);
  return this;
}

Fixed version (ground truth):
@Override public IValue resolve(MarkerList markers,IContext context){
  this.firstValue.resolve(markers,context);
  this.lastValue.resolve(markers,context);
  return this;
}
Program: 84678
Project: 84678
Buggy source:
@Override public int getTypeMatch(IType type){
  if (type.isArrayType()) {
    IType elementType=type.getElementType();
    return this.isElementType(elementType) ? 3 : 0;
  }
  if (Types.ITERABLE.equals(type) || RANGE.isSuperTypeOf(type)) {
    IType iterableType=type.resolveType(IterableForStatement.ITERABLE_TYPE);
    return this.isElementType(iterableType) ? 3 : 0;
  }
  return type.isSuperTypeOf(RANGE) ? 2 : 0;
}

Fixed version (ground truth):
@Override public int getTypeMatch(IType type){
  return this.isType(type) ? 3 : 0;
}
Program: 84679
Project: 84679
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  this.value1.check(markers,context);
  this.value2.check(markers,context);
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  this.firstValue.check(markers,context);
  this.lastValue.check(markers,context);
}