nus-yam/ex-repair huggingface dataset:
Program: 84515
Project: 84515
Buggy source:
@Override public void cleanup(IContext context,IClassCompilableList compilableList){
  super.cleanup(context,compilableList);
  if (this.defaultValue != null) {
    compilableList.addCompilable(this);
    this.defaultValue=this.defaultValue.cleanup(context,compilableList);
  }
}

Fixed version (ground truth):
@Override public void cleanup(IContext context,IClassCompilableList compilableList){
  super.cleanup(context,compilableList);
  if (this.defaultValue != null) {
    this.defaultValue=this.defaultValue.cleanup(context,compilableList);
  }
}
Program: 84516
Project: 84516
Buggy source:
@Override public IValue foldConstants(){
  this.value=this.value.foldConstants();
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].foldConstants();
  }
  return this;
}

Fixed version (ground truth):
@Override public IValue foldConstants(){
  if (this.value != null) {
    this.value=this.value.foldConstants();
  }
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].foldConstants();
  }
  return this;
}
Program: 84517
Project: 84517
Buggy source:
@Override public IValue resolve(MarkerList markers,IContext context){
  this.value=this.value.resolve(markers,context);
  IType type=this.value.getType();
  this.value=this.value.withType(type,type,markers,context);
  for (int i=0; i < this.caseCount; i++) {
    MatchCase c=this.cases[i];
    if (this.exhaustive) {
      markers.add(c.getPattern().getPosition(),"String_Node_Str");
    }
    c.resolve(markers,type,context);
    if (c.isExhaustive()) {
      this.exhaustive=true;
    }
  }
  return this;
}

Fixed version (ground truth):
@Override public IValue resolve(MarkerList markers,IContext context){
  IType type;
  if (this.value != null) {
    this.value=this.value.resolve(markers,context);
    type=this.value.getType();
    this.value=this.value.withType(type,type,markers,context);
  }
 else {
    type=Types.ANY;
    markers.add(this.position,"String_Node_Str");
  }
  for (int i=0; i < this.caseCount; i++) {
    MatchCase c=this.cases[i];
    if (this.exhaustive) {
      markers.add(c.getPattern().getPosition(),"String_Node_Str");
    }
    c.resolve(markers,type,context);
    if (c.isExhaustive()) {
      this.exhaustive=true;
    }
  }
  return this;
}
Program: 84518
Project: 84518
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  this.value.check(markers,context);
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].check(markers,context);
  }
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  if (this.value != null) {
    this.value.check(markers,context);
  }
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].check(markers,context);
  }
}
Program: 84519
Project: 84519
Buggy source:
@Override public void checkTypes(MarkerList markers,IContext context){
  this.value.checkTypes(markers,context);
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].checkTypes(markers,context);
  }
}

Fixed version (ground truth):
@Override public void checkTypes(MarkerList markers,IContext context){
  if (this.value != null) {
    this.value.checkTypes(markers,context);
  }
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].checkTypes(markers,context);
  }
}
Program: 84520
Project: 84520
Buggy source:
@Override public IValue cleanup(IContext context,IClassCompilableList compilableList){
  this.value=this.value.cleanup(context,compilableList);
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].cleanup(context,compilableList);
  }
  return this;
}

Fixed version (ground truth):
@Override public IValue cleanup(IContext context,IClassCompilableList compilableList){
  if (this.value != null) {
    this.value=this.value.cleanup(context,compilableList);
  }
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].cleanup(context,compilableList);
  }
  return this;
}
Program: 84521
Project: 84521
Buggy source:
@Override public void resolveTypes(MarkerList markers,IContext context){
  this.value.resolveTypes(markers,context);
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].resolveTypes(markers,context);
  }
}

Fixed version (ground truth):
@Override public void resolveTypes(MarkerList markers,IContext context){
  if (this.value != null) {
    this.value.resolveTypes(markers,context);
  }
  for (int i=0; i < this.caseCount; i++) {
    this.cases[i].resolveTypes(markers,context);
  }
}
Program: 84523
Project: 84523
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  if (this.action != null) {
    this.action.check(markers,new CombiningContext(this,context));
  }
  for (int i=0; i < this.catchBlockCount; i++) {
    CatchBlock block=this.catchBlocks[i];
    if (!Types.THROWABLE.isSuperTypeOf(block.type)) {
      Marker marker=markers.create(block.type.getPosition(),"String_Node_Str");
      marker.addInfo("String_Node_Str" + block.type);
    }
    block.action.check(markers,context);
  }
  if (this.finallyBlock != null) {
    this.finallyBlock.check(markers,context);
  }
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  if (this.action != null) {
    this.action.check(markers,new CombiningContext(this,context));
  }
  for (int i=0; i < this.catchBlockCount; i++) {
    CatchBlock block=this.catchBlocks[i];
    if (!Types.THROWABLE.isSuperTypeOf(block.type)) {
      Marker marker=markers.create(block.position,"String_Node_Str");
      marker.addInfo("String_Node_Str" + block.type);
    }
    block.action.check(markers,context);
  }
  if (this.finallyBlock != null) {
    this.finallyBlock.check(markers,context);
  }
}
Program: 84524
Project: 84524
Buggy source:
private static int getMode(char c,String code,int i){
switch (c) {
case '`':
    return SPECIAL_IDENTIFIER;
case '#':
  if (code.charAt(i + 1) == '[') {
    return GENERIC_CALL;
  }
return IDENTIFIER | MOD_SYMBOL;
case '"':
return STRING;
case '\'':
return CHAR;
case '/':
char n=code.charAt(i + 1);
if (n == '*') {
return BLOCK_COMMENT;
}
 else if (n == '/') {
return LINE_COMMENT;
}
 else {
return IDENTIFIER | MOD_SYMBOL;
}
case '@':
n=code.charAt(i + 1);
if (n == '"') {
return STRING_2;
}
return IDENTIFIER | MOD_SYMBOL;
case '0':
n=code.charAt(i + 1);
if (n == 'b') {
return INT | MOD_BIN;
}
 else if (n == 'x') {
return INT | MOD_HEX;
}
 else if (isDigit(n)) {
return INT | MOD_OCT;
}
return INT;
case '(':
return Symbols.OPEN_PARENTHESIS;
case ')':
return Symbols.CLOSE_PARENTHESIS;
case '[':
return Symbols.OPEN_SQUARE_BRACKET;
case ']':
return Symbols.CLOSE_SQUARE_BRACKET;
case '{':
return Symbols.OPEN_CURLY_BRACKET;
case '}':
return Symbols.CLOSE_CURLY_BRACKET;
case '.':
n=code.charAt(i + 1);
if (n == '.') {
return IDENTIFIER | MOD_DOTS;
}
return Symbols.DOT;
case ';':
return Symbols.SEMICOLON;
case ',':
return Symbols.COMMA;
case '_':
case '$':
return IDENTIFIER | MOD_SYMBOL | MOD_LETTER;
}
if (isDigit(c)) {
return INT;
}
 else if (isIdentifierSymbol(c)) {
return IDENTIFIER | MOD_SYMBOL;
}
 else if (isIdentifierPart(c)) {
return IDENTIFIER | MOD_LETTER;
}
return 0;
}

Fixed version (ground truth):
private static int getMode(char c,String code,int i){
switch (c) {
case '`':
    return SPECIAL_IDENTIFIER;
case '#':
  if (code.charAt(i + 1) == '[') {
    return GENERIC_CALL;
  }
return IDENTIFIER | MOD_SYMBOL;
case '"':
return STRING;
case '\'':
return CHAR;
case '/':
char n=code.charAt(i + 1);
if (n == '*') {
return BLOCK_COMMENT;
}
 else if (n == '/') {
return LINE_COMMENT;
}
 else {
return IDENTIFIER | MOD_SYMBOL;
}
case '@':
n=code.charAt(i + 1);
if (n == '"') {
return STRING_2;
}
return IDENTIFIER | MOD_SYMBOL;
case '0':
n=code.charAt(i + 1);
if (n == 'b') {
return INT | MOD_BIN;
}
 else if (n == 'x') {
return INT | MOD_HEX;
}
 else if (isDigit(n)) {
return INT | MOD_OCT;
}
return INT;
case '(':
return Symbols.OPEN_PARENTHESIS;
case ')':
return Symbols.CLOSE_PARENTHESIS;
case '[':
return Symbols.OPEN_SQUARE_BRACKET;
case ']':
return Symbols.CLOSE_SQUARE_BRACKET;
case '{':
return Symbols.OPEN_CURLY_BRACKET;
case '}':
return Symbols.CLOSE_CURLY_BRACKET;
case '.':
n=code.charAt(i + 1);
if (n == '.') {
return IDENTIFIER | MOD_DOTS;
}
return Symbols.DOT;
case ';':
return Symbols.SEMICOLON;
case ',':
return Symbols.COMMA;
case '_':
case '$':
return IDENTIFIER | MOD_SYMBOL | MOD_LETTER;
case '-':
if (isDigit(code.charAt(i + 1))) {
return INT;
}
return IDENTIFIER | MOD_SYMBOL;
}
if (isDigit(c)) {
return INT;
}
 else if (isIdentifierSymbol(c)) {
return IDENTIFIER | MOD_SYMBOL;
}
 else if (isIdentifierPart(c)) {
return IDENTIFIER | MOD_LETTER;
}
return 0;
}
Program: 84526
Project: 84526
Buggy source:
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  if (this.mode == ACTION) {
    pm.pushParser(pm.newExpressionParser(this),true);
    this.mode=CATCH;
    return;
  }
  int type=token.type();
  if (this.mode == CATCH) {
    if (type == Keywords.CATCH) {
      this.statement.addCatchBlock(this.catchBlock=new CatchBlock(token.raw()));
      this.mode=CATCH_OPEN;
      return;
    }
    if (type == Keywords.FINALLY) {
      pm.popParser();
      pm.pushParser(pm.newExpressionParser(this));
      this.mode=0;
      return;
    }
    if (ParserUtil.isTerminator(type)) {
      int next=token.next().type();
      if (next != Keywords.CATCH && next != Keywords.FINALLY) {
        pm.popParser(true);
      }
      return;
    }
    pm.popParser(true);
  }
  if (this.mode == CATCH_OPEN) {
    this.mode=CATCH_VAR;
    pm.pushParser(pm.newTypeParser(this.catchBlock));
    if (type == Symbols.OPEN_PARENTHESIS) {
      return;
    }
    throw new SyntaxError(token,"String_Node_Str",true);
  }
  if (this.mode == CATCH_VAR) {
    this.mode=CATCH_CLOSE;
    if (ParserUtil.isIdentifier(type)) {
      this.catchBlock.varName=token.nameValue();
      return;
    }
    throw new SyntaxError(token,"String_Node_Str",true);
  }
  if (this.mode == CATCH_CLOSE) {
    this.mode=CATCH;
    pm.pushParser(pm.newExpressionParser(this.catchBlock));
    if (type == Symbols.CLOSE_PARENTHESIS) {
      return;
    }
    throw new SyntaxError(token,"String_Node_Str");
  }
}

Fixed version (ground truth):
@Override public void parse(IParserManager pm,IToken token) throws SyntaxError {
  if (this.mode == ACTION) {
    pm.pushParser(pm.newExpressionParser(this),true);
    this.mode=CATCH;
    return;
  }
  int type=token.type();
  if (this.mode == CATCH) {
    if (type == Keywords.CATCH) {
      this.statement.addCatchBlock(this.catchBlock=new CatchBlock(token.raw()));
      this.mode=CATCH_OPEN;
      return;
    }
    if (type == Keywords.FINALLY) {
      pm.popParser();
      pm.pushParser(pm.newExpressionParser(this));
      this.mode=0;
      return;
    }
    if (ParserUtil.isTerminator(type)) {
      IToken next=token.getNext();
      if (next == null) {
        pm.popParser(true);
        return;
      }
      int nextType=token.next().type();
      if (nextType != Keywords.CATCH && nextType != Keywords.FINALLY) {
        pm.popParser(true);
      }
      return;
    }
    pm.popParser(true);
  }
  if (this.mode == CATCH_OPEN) {
    this.mode=CATCH_VAR;
    pm.pushParser(pm.newTypeParser(this.catchBlock));
    if (type == Symbols.OPEN_PARENTHESIS) {
      return;
    }
    throw new SyntaxError(token,"String_Node_Str",true);
  }
  if (this.mode == CATCH_VAR) {
    this.mode=CATCH_CLOSE;
    if (ParserUtil.isIdentifier(type)) {
      this.catchBlock.varName=token.nameValue();
      return;
    }
    throw new SyntaxError(token,"String_Node_Str",true);
  }
  if (this.mode == CATCH_CLOSE) {
    this.mode=CATCH;
    pm.pushParser(pm.newExpressionParser(this.catchBlock));
    if (type == Symbols.CLOSE_PARENTHESIS) {
      return;
    }
    throw new SyntaxError(token,"String_Node_Str");
  }
}
Program: 84527
Project: 84527
Buggy source:
public static synchronized void loop(){
  System.out.print("String_Node_Str");
  try {
    currentCode=reader.readLine();
    TokenIterator tokens=Dlex.tokenIterator(currentCode + "String_Node_Str");
    REPLContext.newClassName();
    if (parser.parse(tokens,new DyvilUnitParser(context))) {
      return;
    }
    if (parser.parse(tokens,new ClassBodyParser(context))) {
      return;
    }
    if (parser.parse(tokens,new ExpressionParser(context))) {
      return;
    }
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
}

Fixed version (ground truth):
public static synchronized void loop(){
  System.out.print("String_Node_Str");
  try {
    currentCode=reader.readLine();
    TokenIterator tokens=Dlex.tokenIterator(currentCode + "String_Node_Str");
    REPLContext.newClassName();
    if (parser.parse(null,tokens,new DyvilUnitParser(context))) {
      return;
    }
    if (parser.parse(null,tokens,new ClassBodyParser(context))) {
      return;
    }
    MarkerList markers=new MarkerList();
    parser.parse(markers,tokens,new ExpressionParser(context));
    StringBuilder buf=new StringBuilder();
    for (    Marker m : markers) {
      m.log(currentCode,buf);
    }
    System.out.println(buf.toString());
  }
 catch (  Throwable t) {
    t.printStackTrace();
  }
}
Program: 84528
Project: 84528
Buggy source:
public boolean parse(TokenIterator tokens,Parser parser){
  this.tokens=tokens;
  this.parser=parser;
  this.skip=0;
  this.reparse=false;
  IToken token=null, prev=null;
  tokens.reset();
  while (tokens.hasNext()) {
    token=tokens.next();
    token.setPrev(prev);
    prev=token;
  }
  if (prev == null) {
    return false;
  }
  int type=prev.type();
  if (!ParserUtil.isSeperator(type) && type != (Tokens.IDENTIFIER | Tokens.MOD_SYMBOL)) {
    IToken semicolon=new InferredSemicolon(prev.endLine(),prev.endIndex());
    semicolon.setPrev(prev);
    prev.setNext(semicolon);
  }
  tokens.reset();
  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) {
      return false;
    }
catch (    Exception ex) {
      ex.printStackTrace();
      return false;
    }
    if (this.parser == null) {
      break;
    }
    if (DyvilCompiler.parseStack) {
      System.out.println(token + "String_Node_Str" + this.parser.getName()+ "String_Node_Str"+ this.parser.getMode());
    }
  }
  return true;
}

Fixed version (ground truth):
public boolean parse(MarkerList markers,TokenIterator tokens,Parser parser){
  this.tokens=tokens;
  this.parser=parser;
  this.skip=0;
  this.reparse=false;
  IToken token=null, prev=null;
  tokens.reset();
  while (tokens.hasNext()) {
    token=tokens.next();
    token.setPrev(prev);
    prev=token;
  }
  if (prev == null) {
    return false;
  }
  int type=prev.type();
  if (!ParserUtil.isSeperator(type) && type != (Tokens.IDENTIFIER | Tokens.MOD_SYMBOL)) {
    IToken semicolon=new InferredSemicolon(prev.endLine(),prev.endIndex());
    semicolon.setPrev(prev);
    prev.setNext(semicolon);
  }
  tokens.reset();
  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 (markers == null) {
        return false;
      }
      markers.add(ex);
    }
catch (    Exception ex) {
      ex.printStackTrace();
      return false;
    }
    if (this.parser == null) {
      break;
    }
    if (DyvilCompiler.parseStack) {
      System.out.println(token + "String_Node_Str" + this.parser.getName()+ "String_Node_Str"+ this.parser.getMode());
    }
  }
  return true;
}
Program: 84529
Project: 84529
Buggy source:
private static boolean isAdaptableTo(Class<?> fromType,Class<?> toType,boolean strict){
  if (fromType.equals(toType)) {
    return true;
  }
  if (fromType.isPrimitive()) {
    Wrapper wfrom=forPrimitiveType(fromType);
    if (toType.isPrimitive()) {
      Wrapper wto=forPrimitiveType(toType);
      return wto.isConvertibleFrom(wfrom);
    }
    return toType.isAssignableFrom(wfrom.wrapperType());
  }
  if (toType.isPrimitive()) {
    Wrapper wfrom;
    if (isWrapperType(fromType) && (wfrom=forWrapperType(fromType)).primitiveType().isPrimitive()) {
      Wrapper wto=forPrimitiveType(toType);
      return wto.isConvertibleFrom(wfrom);
    }
    return !strict;
  }
  return !strict || toType.isAssignableFrom(fromType);
}

Fixed version (ground truth):
private static boolean isAdaptableTo(Class<?> fromType,Class<?> toType,boolean strict){
  if (fromType.equals(toType)) {
    return true;
  }
  if (fromType.isPrimitive()) {
    Wrapper wfrom=Wrapper.forPrimitiveType(fromType);
    if (toType.isPrimitive()) {
      Wrapper wto=Wrapper.forPrimitiveType(toType);
      return wto.isConvertibleFrom(wfrom);
    }
    return toType.isAssignableFrom(wfrom.wrapperType());
  }
  if (toType.isPrimitive()) {
    Wrapper wfrom;
    if (Wrapper.isWrapperType(fromType) && (wfrom=Wrapper.forWrapperType(fromType)).primitiveType().isPrimitive()) {
      Wrapper wto=Wrapper.forPrimitiveType(toType);
      return wto.isConvertibleFrom(wfrom);
    }
    return !strict;
  }
  return !strict || toType.isAssignableFrom(fromType);
}
Program: 84530
Project: 84530
Buggy source:
private void convertArgumentTypes(MethodType samType){
  int lvIndex=0;
  boolean samIncludesReceiver=AnonymousClassLMF.this.implIsInstanceMethod && AnonymousClassLMF.this.invokedType.parameterCount() == 0;
  int samReceiverLength=samIncludesReceiver ? 1 : 0;
  if (samIncludesReceiver) {
    Class<?> rcvrType=samType.parameterType(0);
    this.visitVarInsn(getLoadOpcode(rcvrType),lvIndex + 1);
    lvIndex+=getParameterSize(rcvrType);
    TypeConverter.convertType(this,rcvrType,AnonymousClassLMF.this.implDefiningClass,AnonymousClassLMF.this.instantiatedMethodType.parameterType(0));
  }
  int samParametersLength=samType.parameterCount();
  int argOffset=AnonymousClassLMF.this.implMethodType.parameterCount() - samParametersLength;
  for (int i=samReceiverLength; i < samParametersLength; i++) {
    Class<?> argType=samType.parameterType(i);
    this.visitVarInsn(getLoadOpcode(argType),lvIndex + 1);
    lvIndex+=getParameterSize(argType);
    TypeConverter.convertType(this,argType,AnonymousClassLMF.this.implMethodType.parameterType(argOffset + i),AnonymousClassLMF.this.instantiatedMethodType.parameterType(i));
  }
}

Fixed version (ground truth):
private void convertArgumentTypes(MethodType samType){
  int lvIndex=0;
  boolean samIncludesReceiver=AnonymousClassLMF.this.implIsInstanceMethod && AnonymousClassLMF.this.invokedType.parameterCount() == 0;
  int samReceiverLength=samIncludesReceiver ? 1 : 0;
  if (samIncludesReceiver) {
    Class<?> rcvrType=samType.parameterType(0);
    this.mv.visitVarInsn(getLoadOpcode(rcvrType),lvIndex + 1);
    lvIndex+=getParameterSize(rcvrType);
    TypeConverter.convertType(this.mv,rcvrType,AnonymousClassLMF.this.implDefiningClass,AnonymousClassLMF.this.instantiatedMethodType.parameterType(0));
  }
  int samParametersLength=samType.parameterCount();
  int argOffset=AnonymousClassLMF.this.implMethodType.parameterCount() - samParametersLength;
  for (int i=samReceiverLength; i < samParametersLength; i++) {
    Class<?> argType=samType.parameterType(i);
    this.mv.visitVarInsn(getLoadOpcode(argType),lvIndex + 1);
    lvIndex+=getParameterSize(argType);
    TypeConverter.convertType(this.mv,argType,AnonymousClassLMF.this.implMethodType.parameterType(argOffset + i),AnonymousClassLMF.this.instantiatedMethodType.parameterType(i));
  }
}
Program: 84531
Project: 84531
Buggy source:
public AnonymousClassLMF(MethodHandles.Lookup caller,MethodType invokedType,String samMethodName,MethodType samMethodType,MethodHandle implMethod,MethodType instantiatedMethodType,String toString) throws LambdaConversionException {
  super(caller,invokedType,samMethodName,samMethodType,implMethod,instantiatedMethodType);
  this.implMethodClassName=this.implDefiningClass.getName().replace('.','/');
  this.implMethodName=this.implInfo.getName();
  this.implMethodDesc=this.implMethodType.toMethodDescriptorString();
  this.implMethodReturnClass=this.implKind == MethodHandleInfo.REF_newInvokeSpecial ? this.implDefiningClass : this.implMethodType.returnType();
  this.constructorType=invokedType.changeReturnType(Void.TYPE);
  this.lambdaClassName=this.targetClass.getName().replace('.','/') + "String_Node_Str" + counter.incrementAndGet();
  this.cw=new ClassWriter(ClassWriter.COMPUTE_MAXS);
  int parameterCount=invokedType.parameterCount();
  if (parameterCount > 0) {
    this.argNames=new String[parameterCount];
    this.argDescs=new String[parameterCount];
    for (int i=0; i < parameterCount; i++) {
      this.argNames[i]="String_Node_Str" + (i + 1);
      this.argDescs[i]=BytecodeDescriptor.unparse(invokedType.parameterType(i));
    }
  }
 else {
    this.argNames=this.argDescs=EMPTY_STRING_ARRAY;
  }
  this.toString=toString;
}

Fixed version (ground truth):
public AnonymousClassLMF(MethodHandles.Lookup caller,MethodType invokedType,String samMethodName,MethodType samMethodType,MethodHandle implMethod,MethodType instantiatedMethodType,String toString) throws LambdaConversionException {
  super(caller,invokedType,samMethodName,samMethodType,implMethod,instantiatedMethodType);
  this.implMethodClassName=this.implDefiningClass.getName().replace('.','/');
  this.implMethodName=this.implInfo.getName();
  this.implMethodDesc=this.implMethodType.toMethodDescriptorString();
  this.implMethodReturnClass=this.implKind == MethodHandleInfo.REF_newInvokeSpecial ? this.implDefiningClass : this.implMethodType.returnType();
  this.constructorType=invokedType.changeReturnType(Void.TYPE);
  this.lambdaClassName=this.targetClass.getName().replace('.','/') + "String_Node_Str" + counter.incrementAndGet();
  this.cw=new ClassWriter(ClassWriter.COMPUTE_MAXS);
  int parameterCount=invokedType.parameterCount();
  if (parameterCount > 0) {
    this.argNames=new String[parameterCount];
    this.argDescs=new String[parameterCount];
    for (int i=0; i < parameterCount; i++) {
      this.argNames[i]="String_Node_Str" + (i + 1);
      this.argDescs[i]=Type.getDescriptor(invokedType.parameterType(i));
    }
  }
 else {
    this.argNames=this.argDescs=EMPTY_STRING_ARRAY;
  }
  this.toString=toString;
}
Program: 84532
Project: 84532
Buggy source:
void generate(MethodType methodType){
  this.visitCode();
  if (AnonymousClassLMF.this.implKind == MethodHandleInfo.REF_newInvokeSpecial) {
    this.visitTypeInsn(NEW,AnonymousClassLMF.this.implMethodClassName);
    this.visitInsn(DUP);
  }
  for (int i=0; i < AnonymousClassLMF.this.argNames.length; i++) {
    this.visitVarInsn(ALOAD,0);
    this.visitFieldInsn(GETFIELD,AnonymousClassLMF.this.lambdaClassName,AnonymousClassLMF.this.argNames[i],AnonymousClassLMF.this.argDescs[i]);
  }
  this.convertArgumentTypes(methodType);
  this.visitMethodInsn(this.invocationOpcode(),AnonymousClassLMF.this.implMethodClassName,AnonymousClassLMF.this.implMethodName,AnonymousClassLMF.this.implMethodDesc,AnonymousClassLMF.this.implDefiningClass.isInterface());
  Class<?> samReturnClass=methodType.returnType();
  TypeConverter.convertType(this,AnonymousClassLMF.this.implMethodReturnClass,samReturnClass,samReturnClass);
  this.visitInsn(getReturnOpcode(samReturnClass));
  this.visitMaxs(-1,-1);
  this.visitEnd();
}

Fixed version (ground truth):
void generate(MethodType methodType){
  this.mv.visitCode();
  if (AnonymousClassLMF.this.implKind == MethodHandleInfo.REF_newInvokeSpecial) {
    this.mv.visitTypeInsn(NEW,AnonymousClassLMF.this.implMethodClassName);
    this.mv.visitInsn(DUP);
  }
  for (int i=0; i < AnonymousClassLMF.this.argNames.length; i++) {
    this.mv.visitVarInsn(ALOAD,0);
    this.mv.visitFieldInsn(GETFIELD,AnonymousClassLMF.this.lambdaClassName,AnonymousClassLMF.this.argNames[i],AnonymousClassLMF.this.argDescs[i]);
  }
  this.convertArgumentTypes(methodType);
  this.mv.visitMethodInsn(this.invocationOpcode(),AnonymousClassLMF.this.implMethodClassName,AnonymousClassLMF.this.implMethodName,AnonymousClassLMF.this.implMethodDesc,AnonymousClassLMF.this.implDefiningClass.isInterface());
  Class<?> samReturnClass=methodType.returnType();
  TypeConverter.convertType(this.mv,AnonymousClassLMF.this.implMethodReturnClass,samReturnClass,samReturnClass);
  this.mv.visitInsn(getReturnOpcode(samReturnClass));
  this.mv.visitMaxs(-1,-1);
  this.mv.visitEnd();
}
Program: 84533
Project: 84533
Buggy source:
ForwardingMethodGenerator(MethodVisitor mv){
  super(dyvil.tools.asm.Opcodes.ASM5,mv);
}

Fixed version (ground truth):
ForwardingMethodGenerator(MethodVisitor mv){
  this.mv=mv;
}
Program: 84535
Project: 84535
Buggy source:
public IType getElementType(){
  if (this.elementType != null) {
    return this.elementType;
  }
  int len=this.valueCount;
  if (len == 0) {
    this.elementType=Types.ANY;
    return this.requiredType=new ArrayType(Types.ANY);
  }
  IType t=this.values[0].getType();
  for (int i=1; i < len; i++) {
    IType t1=this.values[i].getType();
    t=Types.combine(t,t1);
    if (t == null) {
      t=Types.ANY;
      break;
    }
  }
  return this.elementType=t;
}

Fixed version (ground truth):
public IType getElementType(){
  if (this.elementType != null) {
    return this.elementType;
  }
  int len=this.valueCount;
  if (len == 0) {
    return this.elementType=Types.ANY;
  }
  IType t=this.values[0].getType();
  for (int i=1; i < len; i++) {
    IType t1=this.values[i].getType();
    t=Types.combine(t,t1);
    if (t == null) {
      t=Types.ANY;
      break;
    }
  }
  return this.elementType=t;
}
Program: 84537
Project: 84537
Buggy source:
@Override public IValue withType(IType arrayType,ITypeContext typeContext,MarkerList markers,IContext context){
  IType elementType;
  if (!arrayType.isArrayType()) {
    IClass iclass=arrayType.getTheClass();
    if (iclass.getAnnotation(Types.ARRAY_CONVERTIBLE) != null) {
      return new LiteralExpression(this).withType(arrayType,typeContext,markers,context);
    }
    if (arrayType.classEquals(Types.ITERABLE)) {
      return new LiteralExpression(this,getArrayToIterable()).withType(arrayType,typeContext,markers,context);
    }
 else     if (iclass != Types.OBJECT_CLASS) {
      return null;
    }
 else {
      elementType=this.getElementType();
    }
  }
 else {
    elementType=arrayType.getElementType();
  }
  for (int i=0; i < this.valueCount; i++) {
    if (!this.values[i].isType(elementType)) {
      return null;
    }
  }
  for (int i=0; i < this.valueCount; i++) {
    IValue value=this.values[i];
    IValue value1=value.withType(elementType,typeContext,markers,context);
    if (value1 == null) {
      Marker marker=markers.create(value.getPosition(),"String_Node_Str");
      marker.addInfo("String_Node_Str" + this.requiredType);
      marker.addInfo("String_Node_Str" + value.getType());
    }
 else {
      value=value1;
      this.values[i]=value1;
    }
  }
  this.elementType=elementType;
  this.requiredType=arrayType;
  return this;
}

Fixed version (ground truth):
@Override public IValue withType(IType arrayType,ITypeContext typeContext,MarkerList markers,IContext context){
  IType elementType;
  if (!arrayType.isArrayType()) {
    IClass iclass=arrayType.getTheClass();
    if (iclass.getAnnotation(Types.ARRAY_CONVERTIBLE) != null) {
      return new LiteralExpression(this).withType(arrayType,typeContext,markers,context);
    }
    if (arrayType.classEquals(Types.ITERABLE)) {
      return new LiteralExpression(this,getArrayToIterable()).withType(arrayType,typeContext,markers,context);
    }
 else     if (iclass != Types.OBJECT_CLASS) {
      return null;
    }
 else {
      elementType=this.getElementType();
    }
  }
 else {
    elementType=arrayType.getElementType();
  }
  for (int i=0; i < this.valueCount; i++) {
    if (!this.values[i].isType(elementType)) {
      return null;
    }
  }
  for (int i=0; i < this.valueCount; i++) {
    IValue value=this.values[i];
    IValue value1=value.withType(elementType,typeContext,markers,context);
    if (value1 == null) {
      Marker marker=markers.create(value.getPosition(),"String_Node_Str");
      marker.addInfo("String_Node_Str" + this.requiredType);
      marker.addInfo("String_Node_Str" + value.getType());
    }
 else {
      value=value1;
      this.values[i]=value1;
    }
  }
  if (arrayType.hasTypeVariables()) {
    this.getType();
    return this;
  }
  this.elementType=elementType;
  this.requiredType=arrayType;
  return this;
}
Program: 84538
Project: 84538
Buggy source:
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (this.then == null) {
    return null;
  }
  IValue then1=this.then.withType(type,typeContext,markers,context);
  if (then1 == null) {
    return null;
  }
  this.then=then1;
  if (this.elseThen != null) {
    then1=this.elseThen.withType(type,typeContext,markers,context);
    if (then1 == null) {
      return null;
    }
    this.elseThen=then1;
  }
  this.commonType=type;
  return this;
}

Fixed version (ground truth):
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (this.then == null) {
    return null;
  }
  IValue then1=this.then.withType(type,typeContext,markers,context);
  if (then1 == null) {
    return null;
  }
  this.then=then1;
  if (this.elseThen != null) {
    then1=this.elseThen.withType(type,typeContext,markers,context);
    if (then1 == null) {
      return null;
    }
    this.elseThen=then1;
    this.commonType=Types.combine(this.then.getType(),this.elseThen.getType());
    return this;
  }
  this.commonType=this.then.getType();
  return this;
}
Program: 84539
Project: 84539
Buggy source:
@Override public IValue cleanup(IContext context,IClassCompilableList compilableList){
  if (this.condition != null) {
    this.condition=this.condition.cleanup(context,compilableList);
  }
  if (this.then != null) {
    this.then=this.then.cleanup(context,compilableList);
  }
  if (this.elseThen != null) {
    this.elseThen=this.elseThen.cleanup(context,compilableList);
  }
  return this;
}

Fixed version (ground truth):
@Override public IValue cleanup(IContext context,IClassCompilableList compilableList){
  if (this.condition != null) {
    this.condition=this.condition.cleanup(context,compilableList);
  }
  if (this.then != null) {
    this.then=this.then.cleanup(context,compilableList);
  }
  if (this.elseThen != null) {
    this.elseThen=this.elseThen.cleanup(context,compilableList);
  }
  if ((this.condition.valueTag() == BOOLEAN)) {
    return ((BooleanValue)this.condition).value ? this.then : this.elseThen;
  }
  return this;
}
Program: 84540
Project: 84540
Buggy source:
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (type == Types.VOID || type == Types.UNKNOWN) {
    this.requiredType=Types.VOID;
    return this;
  }
  if (this.valueCount > 0) {
    IValue v=this.values[this.valueCount - 1].withType(type,typeContext,markers,context);
    if (v != null) {
      this.values[this.valueCount - 1]=v;
      this.requiredType=type;
      return this;
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public IValue withType(IType type,ITypeContext typeContext,MarkerList markers,IContext context){
  if (type == Types.VOID) {
    this.requiredType=Types.VOID;
    return this;
  }
  if (this.valueCount > 0) {
    IValue v=this.values[this.valueCount - 1].withType(type,typeContext,markers,context);
    if (v != null) {
      this.values[this.valueCount - 1]=v;
      this.requiredType=v.getType();
      return this;
    }
  }
  return null;
}
Program: 84541
Project: 84541
Buggy source:
public static IType combine(IType type1,IType type2){
  if (type1.equals(type2)) {
    return type1;
  }
  Set<IType> types1=superTypes(type1);
  Set<IType> types2=superTypes(type2);
  for (  IType t1 : types1) {
    IClass class1=t1.getTheClass();
    if (class1 == Types.OBJECT_CLASS) {
      continue;
    }
    for (    IType t2 : types2) {
      if (class1 == t2.getTheClass()) {
        return new ClassType(class1);
      }
    }
  }
  return Types.ANY;
}

Fixed version (ground truth):
public static IType combine(IType type1,IType type2){
  if (type1.equals(type2)) {
    return type1;
  }
  if (type1.typeTag() == IType.NULL) {
    return type2.getReferenceType();
  }
  if (type2.typeTag() == IType.NULL) {
    return type1.getReferenceType();
  }
  Set<IType> types1=superTypes(type1);
  Set<IType> types2=superTypes(type2);
  for (  IType t1 : types1) {
    IClass class1=t1.getTheClass();
    if (class1 == Types.OBJECT_CLASS) {
      continue;
    }
    for (    IType t2 : types2) {
      if (class1 == t2.getTheClass()) {
        return new ClassType(class1);
      }
    }
  }
  return Types.ANY;
}
Program: 84543
Project: 84543
Buggy source:
@Override public void check(){
  this.pack.check(this.packageDeclaration,this.inputFile,this.markers);
}

Fixed version (ground truth):
@Override public void check(){
  this.pack.check(this.packageDeclaration,this.markers);
}
Program: 84544
Project: 84544
Buggy source:
@Override public void check(){
  this.pack.check(this.packageDeclaration,this.inputFile,this.markers);
  for (int i=0; i < this.classCount; i++) {
    this.classes[i].check(this.markers,this);
  }
}

Fixed version (ground truth):
@Override public void check(){
  this.pack.check(this.packageDeclaration,this.markers);
  for (int i=0; i < this.classCount; i++) {
    this.classes[i].check(this.markers,this);
  }
}
Program: 84545
Project: 84545
Buggy source:
public void check(PackageDeclaration packageDecl,CodeFile file,MarkerList markers){
  if (packageDecl == null) {
    if (this.fullName != null) {
      markers.add(new CodePosition(0,0,1),"String_Node_Str");
    }
    return;
  }
  if (this.fullName == null) {
    markers.add(packageDecl.getPosition(),"String_Node_Str");
    return;
  }
  if (!this.fullName.equals(packageDecl.thePackage)) {
    markers.add(packageDecl.getPosition(),"String_Node_Str");
  }
}

Fixed version (ground truth):
public void check(PackageDeclaration packageDecl,MarkerList markers){
  if (packageDecl == null) {
    markers.add(new CodePosition(0,0,1),"String_Node_Str");
    return;
  }
  if (!this.fullName.equals(packageDecl.thePackage)) {
    markers.add(packageDecl.getPosition(),"String_Node_Str",this.fullName);
  }
}
Program: 84546
Project: 84546
Buggy source:
public Package(Package parent,Name name){
  this.name=name;
  this.parent=parent;
  if (parent == null || parent.name == null) {
    this.fullName=name.qualified;
    this.internalName=ClassFormat.packageToInternal(name.qualified) + "String_Node_Str";
  }
 else {
    this.fullName=parent.fullName + "String_Node_Str" + name.qualified;
    this.internalName=parent.internalName + name.qualified + "String_Node_Str";
  }
}

Fixed version (ground truth):
public Package(Package parent,Name name){
  this.name=name;
  this.parent=parent;
  if (parent == null || parent == rootPackage) {
    this.fullName=name.qualified;
    this.internalName=ClassFormat.packageToInternal(name.qualified) + "String_Node_Str";
  }
 else {
    this.fullName=parent.fullName + "String_Node_Str" + name.qualified;
    this.internalName=parent.internalName + name.qualified + "String_Node_Str";
  }
}
Program: 84547
Project: 84547
Buggy source:
public RootPackage(){
}

Fixed version (ground truth):
public RootPackage(){
  this.internalName=this.fullName="String_Node_Str";
  this.name=Name.getQualified("String_Node_Str");
}
Program: 84548
Project: 84548
Buggy source:
@Override public void getMethodMatches(List<MethodMatch> list,IValue instance,Name name,IArguments arguments){
  if (!this.genericsResolved) {
    this.resolveGenerics();
  }
  this.body.getMethodMatches(list,instance,name,arguments);
  if (!list.isEmpty()) {
    return;
  }
  if (!this.superTypesResolved) {
    this.resolveSuperTypes();
  }
  if (this.superType != null && this.superType.getTheClass() != Types.OBJECT_CLASS) {
    this.superType.getMethodMatches(list,instance,name,arguments);
  }
  if (!list.isEmpty()) {
    return;
  }
  for (int i=0; i < this.interfaceCount; i++) {
    this.interfaces[i].getMethodMatches(list,instance,name,arguments);
  }
}

Fixed version (ground truth):
@Override public void getMethodMatches(List<MethodMatch> list,IValue instance,Name name,IArguments arguments){
  if (!this.genericsResolved) {
    this.resolveGenerics();
  }
  this.body.getMethodMatches(list,instance,name,arguments);
  if (!list.isEmpty()) {
    return;
  }
  if (!this.superTypesResolved) {
    this.resolveSuperTypes();
  }
  if (this.superType != null) {
    this.superType.getMethodMatches(list,instance,name,arguments);
  }
  if (!list.isEmpty()) {
    return;
  }
  for (int i=0; i < this.interfaceCount; i++) {
    this.interfaces[i].getMethodMatches(list,instance,name,arguments);
  }
}
Program: 84549
Project: 84549
Buggy source:
private void inferTypes(GenericData genericData,IValue instance,IArguments arguments){
  if (instance != null) {
    genericData.instanceType=instance.getType();
  }
 else {
    genericData.instanceType=this.theClass.getType();
  }
  int len=arguments.size();
  IParameter param;
  if (instance != null && (this.modifiers & Modifiers.INFIX) == Modifiers.INFIX) {
    this.parameters[0].getType().inferTypes(instance.getType(),genericData);
    for (int i=0; i < len - 1; i++) {
      param=this.parameters[i + 1];
      param.getType().inferTypes(arguments.getType(i,param),genericData);
    }
  }
 else {
    len=Math.min(this.parameterCount,len);
    for (int i=0; i < len; i++) {
      param=this.parameters[i];
      param.getType().inferTypes(arguments.getType(i,param),genericData);
    }
  }
}

Fixed version (ground truth):
private void inferTypes(GenericData genericData,IValue instance,IArguments arguments){
  if (instance != null) {
    genericData.instanceType=instance.getType();
  }
 else {
    genericData.instanceType=this.theClass.getType();
  }
  int len=arguments.size();
  IParameter param;
  if (instance != null && (this.modifiers & Modifiers.INFIX) == Modifiers.INFIX) {
    this.parameters[0].getType().inferTypes(instance.getType(),genericData);
    for (int i=0; i < len; i++) {
      param=this.parameters[i + 1];
      param.getType().inferTypes(arguments.getType(i,param),genericData);
    }
  }
 else {
    len=Math.min(this.parameterCount,len);
    for (int i=0; i < len; i++) {
      param=this.parameters[i];
      param.getType().inferTypes(arguments.getType(i,param),genericData);
    }
  }
}
Program: 84550
Project: 84550
Buggy source:
public static void readMethodType(String desc,IMethodSignature method){
  int i=1;
  if (desc.charAt(0) == '<') {
    while (desc.charAt(i) != '>') {
      i=readGeneric(desc,i,method);
    }
    i+=2;
  }
  while (desc.charAt(i) != ')') {
    i=readTypeList(desc,i,method);
  }
  i++;
  i=readTyped(desc,i,method);
  int len=desc.length();
  while (i < len && desc.charAt(i) == '^') {
    i=readException(desc,i + 1,method);
  }
}

Fixed version (ground truth):
public static void readMethodType(String desc,IMethodSignature method){
  int i=1;
  if (desc.charAt(0) == '<') {
    while (desc.charAt(i) != '>') {
      i=readGeneric(desc,i,method);
    }
    i+=2;
  }
  while (desc.charAt(i) != ')') {
    i=readTyped(desc,i,method::addType);
  }
  i++;
  i=readTyped(desc,i,method);
  int len=desc.length();
  while (i < len && desc.charAt(i) == '^') {
    i=readException(desc,i + 1,method);
  }
}
Program: 84551
Project: 84551
Buggy source:
private static int readGeneric(String desc,int start,IGeneric generic){
  int index=desc.indexOf(':',start);
  Name name=Name.getQualified(desc.substring(start,index));
  TypeVariable typeVar=new TypeVariable(generic,name);
  if (desc.charAt(index + 1) == ':') {
    index++;
    typeVar.addUpperBound(Types.OBJECT);
  }
  while (desc.charAt(index) == ':') {
    index=readTypeList(desc,index + 1,typeVar);
  }
  generic.addTypeVariable(typeVar);
  return index;
}

Fixed version (ground truth):
private static int readGeneric(String desc,int start,IGeneric generic){
  int index=desc.indexOf(':',start);
  Name name=Name.getQualified(desc.substring(start,index));
  TypeVariable typeVar=new TypeVariable(generic,name);
  if (desc.charAt(index + 1) == ':') {
    index++;
    typeVar.addUpperBound(Types.OBJECT);
  }
  while (desc.charAt(index) == ':') {
    index=readTyped(desc,index + 1,typeVar::addUpperBound);
  }
  generic.addTypeVariable(typeVar);
  return index;
}
Program: 84552
Project: 84552
Buggy source:
public static void readConstructorType(String desc,IConstructor constructor){
  int i=1;
  while (desc.charAt(i) != ')') {
    i=readTypeList(desc,i,constructor);
  }
  i+=2;
  int len=desc.length();
  while (i < len && desc.charAt(i) == '^') {
    i=readException(desc,i + 1,constructor);
  }
}

Fixed version (ground truth):
public static void readConstructorType(String desc,IConstructor constructor){
  int i=1;
  while (desc.charAt(i) != ')') {
    i=readTyped(desc,i,constructor::addType);
  }
  i+=2;
  int len=desc.length();
  while (i < len && desc.charAt(i) == '^') {
    i=readException(desc,i + 1,constructor);
  }
}
Program: 84553
Project: 84553
Buggy source:
private static IType readReferenceType(String desc,int start,int end){
  int index=desc.indexOf('<',start);
  if (index >= 0 && index < end) {
    GenericType type=new InternalGenericType(desc.substring(start,index));
    index++;
    while (desc.charAt(index) != '>') {
      index=readTypeList(desc,index,type);
    }
    return type;
  }
  return new InternalType(desc.substring(start,end));
}

Fixed version (ground truth):
private static IType readReferenceType(String desc,int start,int end){
  int index=desc.indexOf('<',start);
  if (index >= 0 && index < end) {
    GenericType type=new InternalGenericType(desc.substring(start,index));
    index++;
    while (desc.charAt(index) != '>') {
      index=readTyped(desc,index,type);
    }
    return type;
  }
  return new InternalType(desc.substring(start,end));
}
Program: 84554
Project: 84554
Buggy source:
public static void readClassSignature(String desc,IClass iclass){
  int i=0;
  if (desc.charAt(0) == '<') {
    i++;
    while (desc.charAt(i) != '>') {
      i=readGeneric(desc,i,iclass);
    }
    i++;
  }
  int len=desc.length();
  i=readTyped(desc,i,iclass);
  while (i < len) {
    i=readTyped(desc,i,t -> iclass.addInterface(t));
  }
}

Fixed version (ground truth):
public static void readClassSignature(String desc,IClass iclass){
  int i=0;
  if (desc.charAt(0) == '<') {
    i++;
    while (desc.charAt(i) != '>') {
      i=readGeneric(desc,i,iclass);
    }
    i++;
  }
  int len=desc.length();
  i=readTyped(desc,i,iclass::setSuperType);
  while (i < len) {
    i=readTyped(desc,i,iclass::addInterface);
  }
}
Program: 84556
Project: 84556
Buggy source:
@Override public void cleanup(IContext context,IClassCompilableList compilableList){
  super.cleanup(context,compilableList);
  for (int i=0; i < this.parameterCount; i++) {
    this.parameters[i].cleanup(this,compilableList);
  }
  if (this.value != null) {
    this.value=this.value.cleanup(this,compilableList);
    if (this.theClass.isInterface() && !this.isStatic()) {
      this.modifiers|=Modifiers.BRIDGE | Modifiers.SYNTHETIC;
    }
  }
}

Fixed version (ground truth):
@Override public void cleanup(IContext context,IClassCompilableList compilableList){
  super.cleanup(context,compilableList);
  for (int i=0; i < this.parameterCount; i++) {
    this.parameters[i].cleanup(this,compilableList);
  }
  if (this.value != null) {
    this.value=this.value.cleanup(this,compilableList);
  }
}
Program: 84558
Project: 84558
Buggy source:
@Override public boolean isEmpty(){
  return false;
}

Fixed version (ground truth):
@Override public boolean isEmpty(){
  return this.value == null;
}
Program: 84560
Project: 84560
Buggy source:
@Override public IValue resolve(MarkerList markers,IContext context){
  this.value=this.value.resolve(markers,context);
  IType type=this.value.getType();
  for (int i=0; i < this.caseCount; i++) {
    CaseExpression c=this.cases[i];
    if (this.exhaustive) {
      markers.add(c.getPosition(),"String_Node_Str");
    }
    IPattern pattern=c.pattern;
    if (pattern == null) {
      continue;
    }
    pattern=pattern.resolve(markers,context);
    if (pattern.isExhaustive()) {
      if (c.condition == null) {
        this.exhaustive=true;
      }
    }
    IPattern pattern1=pattern.withType(type);
    if (pattern1 == null) {
      Marker marker=markers.create(pattern.getPosition(),"String_Node_Str");
      marker.addInfo("String_Node_Str" + pattern.getType());
      marker.addInfo("String_Node_Str" + type);
    }
 else {
      pattern=pattern1;
    }
    pattern.checkTypes(markers,context);
    c.pattern=pattern;
    this.cases[i].resolve(markers,context);
  }
  if (type == Types.BOOLEAN && this.caseCount >= 2) {
    this.exhaustive=true;
  }
  return this;
}

Fixed version (ground truth):
@Override public IValue resolve(MarkerList markers,IContext context){
  this.value=this.value.resolve(markers,context);
  IType type=this.value.getType();
  for (int i=0; i < this.caseCount; i++) {
    CaseExpression c=this.cases[i];
    if (this.exhaustive) {
      markers.add(c.getPosition(),"String_Node_Str");
    }
    IPattern pattern=c.pattern;
    if (pattern == null) {
      continue;
    }
    pattern=pattern.resolve(markers,context);
    if (pattern.isExhaustive()) {
      if (c.condition == null) {
        this.exhaustive=true;
      }
    }
    IPattern pattern1=pattern.withType(type);
    if (pattern1 == null) {
      Marker marker=markers.create(pattern.getPosition(),"String_Node_Str");
      marker.addInfo("String_Node_Str" + pattern.getType());
      marker.addInfo("String_Node_Str" + type);
    }
 else {
      pattern=pattern1;
    }
    c.pattern=pattern;
    this.cases[i].resolve(markers,context);
  }
  if (type == Types.BOOLEAN && this.caseCount >= 2) {
    this.exhaustive=true;
  }
  return this;
}
Program: 84561
Project: 84561
Buggy source:
public FieldVisitor visitField(int access,String name,String desc,String signature,Object value){
  Field field=new ExternalField(this);
  field.setName(Name.get(name));
  field.setModifiers(access);
  field.setType(ClassFormat.extendedToType(signature == null ? desc : signature));
  if (value != null) {
    field.setValue(IValue.fromObject(value));
  }
  if ((this.modifiers & Modifiers.OBJECT_CLASS) != 0 && name.equals("String_Node_Str")) {
    this.metadata.setInstanceField(field);
    return null;
  }
  this.body.addField(field);
  return new SimpleFieldVisitor(field);
}

Fixed version (ground truth):
public FieldVisitor visitField(int access,String name,String desc,String signature,Object value){
  IType type=ClassFormat.extendedToType(signature == null ? desc : signature);
  if (this.classParameters != null) {
    for (    String s : this.classParameters) {
      if (s.equals(name)) {
        ClassParameter param=new ClassParameter(this,access,Name.get(name),type);
        this.addParameter(param);
        return new SimpleFieldVisitor(param);
      }
    }
  }
  ExternalField field=new ExternalField(this,access,Name.get(name),type);
  if (value != null) {
    field.setValue(IValue.fromObject(value));
  }
  if ((this.modifiers & Modifiers.OBJECT_CLASS) != 0 && name.equals("String_Node_Str")) {
    this.getMetadata().setInstanceField(field);
  }
 else {
    this.body.addField(field);
  }
  return new SimpleFieldVisitor(field);
}