nus-yam/ex-repair huggingface dataset:
Program: 82774
Project: 82774
Buggy source:
/** 
 * Returns true if rmr1 is after rmr2, using the latest strategy to determine which is the latest
 * @param rmr1
 * @param rmr2
 * @return
 */
private boolean isAfter(ResolvedModuleRevision rmr1,ResolvedModuleRevision rmr2,Date date){
  ArtifactInfo[] ais=new ArtifactInfo[]{new ResolvedModuleRevisionArtifactInfo(rmr1),new ResolvedModuleRevisionArtifactInfo(rmr2)};
  return getLatestStrategy().findLatest(ais,date) == ais[0];
}

Fixed version (ground truth):
/** 
 * Returns true if rmr1 is after rmr2, using the latest strategy to determine which is the latest
 * @param rmr1
 * @param rmr2
 * @return
 */
private boolean isAfter(ResolvedModuleRevision rmr1,ResolvedModuleRevision rmr2,Date date){
  ArtifactInfo[] ais=new ArtifactInfo[]{new ResolvedModuleRevisionArtifactInfo(rmr1),new ResolvedModuleRevisionArtifactInfo(rmr2)};
  return getLatestStrategy().findLatest(ais,date) != ais[1];
}
Program: 82775
Project: 82775
Buggy source:
public void execute() throws BuildException {
  Ivy ivy=getIvyInstance();
  _organisation=getProperty(_organisation,ivy,"String_Node_Str");
  _module=getProperty(_module,ivy,"String_Node_Str");
  if (_cache == null) {
    _cache=ivy.getDefaultCache();
  }
  _conf=getProperty(_conf,ivy,"String_Node_Str");
  if (_conf.equals("String_Node_Str")) {
    _conf=getProperty(ivy,"String_Node_Str");
  }
  if (_conf == null) {
    throw new BuildException("String_Node_Str");
  }
  if (_todir == null) {
    String t=getProperty(ivy,"String_Node_Str");
    if (t != null) {
      _todir=new File(t);
    }
  }
  _outputpattern=getProperty(_outputpattern,ivy,"String_Node_Str");
  if (_todir != null && _todir.exists()) {
    _todir.mkdirs();
  }
  if (_outputpattern == null) {
    _outputpattern="String_Node_Str";
  }
  if (_todir != null && !_todir.isDirectory()) {
    throw new BuildException("String_Node_Str");
  }
  if (_organisation == null) {
    throw new BuildException("String_Node_Str");
  }
  if (_module == null) {
    throw new BuildException("String_Node_Str");
  }
  try {
    String[] confs=splitConfs(_conf);
    for (int i=0; i < confs.length; i++) {
      if (_xsl) {
        genreport(ivy,_cache,_organisation,_module,confs[i]);
      }
      if (_xml) {
        genxml(ivy,_cache,_organisation,_module,confs[i]);
      }
      if (_graph) {
        gengraph(ivy,_cache,_organisation,_module,confs[i]);
      }
    }
  }
 catch (  IOException e) {
    throw new BuildException("String_Node_Str",e);
  }
}

Fixed version (ground truth):
public void execute() throws BuildException {
  Ivy ivy=getIvyInstance();
  _organisation=getProperty(_organisation,ivy,"String_Node_Str");
  _module=getProperty(_module,ivy,"String_Node_Str");
  if (_cache == null) {
    _cache=ivy.getDefaultCache();
  }
  _conf=getProperty(_conf,ivy,"String_Node_Str");
  if (_conf.equals("String_Node_Str")) {
    _conf=getProperty(ivy,"String_Node_Str");
  }
  if (_conf == null) {
    throw new BuildException("String_Node_Str");
  }
  if (_todir == null) {
    String t=getProperty(ivy,"String_Node_Str");
    if (t != null) {
      _todir=new File(t);
    }
  }
  _outputpattern=getProperty(_outputpattern,ivy,"String_Node_Str");
  if (_todir != null && _todir.exists()) {
    _todir.mkdirs();
  }
  if (_outputpattern == null) {
    _outputpattern="String_Node_Str";
  }
  if (_todir != null && _todir.exists() && !_todir.isDirectory()) {
    throw new BuildException("String_Node_Str");
  }
  if (_organisation == null) {
    throw new BuildException("String_Node_Str");
  }
  if (_module == null) {
    throw new BuildException("String_Node_Str");
  }
  try {
    String[] confs=splitConfs(_conf);
    for (int i=0; i < confs.length; i++) {
      if (_xsl) {
        genreport(ivy,_cache,_organisation,_module,confs[i]);
      }
      if (_xml) {
        genxml(ivy,_cache,_organisation,_module,confs[i]);
      }
      if (_graph) {
        gengraph(ivy,_cache,_organisation,_module,confs[i]);
      }
    }
  }
 catch (  IOException e) {
    throw new BuildException("String_Node_Str",e);
  }
}
Program: 82777
Project: 82777
Buggy source:
private void doFetchDependencies(IvyNode node,String conf){
  Configuration c=node.getConfiguration(conf);
  String[] extendedConfs=c.getExtends();
  if (extendedConfs.length > 0) {
    node.updateConfsToFetch(Arrays.asList(extendedConfs));
  }
  for (int i=0; i < extendedConfs.length; i++) {
    fetchDependencies(node,extendedConfs[i]);
  }
  if (node.getDependencyDescriptor() == null || node.getDependencyDescriptor().isTransitive()) {
    Collection dependencies=node.getDependencies(conf,true);
    for (Iterator iter=dependencies.iterator(); iter.hasNext(); ) {
      IvyNode dep=(IvyNode)iter.next();
      if (dep.isCircular()) {
        Message.warn("String_Node_Str" + node.getId() + "String_Node_Str"+ dep.getId()+ "String_Node_Str");
        continue;
      }
      String[] confs=dep.getRequiredConfigurations(node,conf);
      for (int i=0; i < confs.length; i++) {
        fetchDependencies(dep,confs[i]);
      }
      confs=dep.getConfsToFetch();
      for (int i=0; i < confs.length; i++) {
        fetchDependencies(dep,confs[i]);
      }
    }
  }
}

Fixed version (ground truth):
private void doFetchDependencies(IvyNode node,String conf){
  Configuration c=node.getConfiguration(conf);
  if (c == null) {
    Message.warn("String_Node_Str" + conf + "String_Node_Str"+ node.getResolvedId()+ "String_Node_Str");
    if (node.getParent() != null) {
      Message.warn("String_Node_Str" + node.getParent().getResolvedId());
    }
    return;
  }
  String[] extendedConfs=c.getExtends();
  if (extendedConfs.length > 0) {
    node.updateConfsToFetch(Arrays.asList(extendedConfs));
  }
  for (int i=0; i < extendedConfs.length; i++) {
    fetchDependencies(node,extendedConfs[i]);
  }
  if (node.getDependencyDescriptor() == null || node.getDependencyDescriptor().isTransitive()) {
    Collection dependencies=node.getDependencies(conf,true);
    for (Iterator iter=dependencies.iterator(); iter.hasNext(); ) {
      IvyNode dep=(IvyNode)iter.next();
      if (dep.isCircular()) {
        Message.warn("String_Node_Str" + node.getId() + "String_Node_Str"+ dep.getId()+ "String_Node_Str");
        continue;
      }
      String[] confs=dep.getRequiredConfigurations(node,conf);
      for (int i=0; i < confs.length; i++) {
        fetchDependencies(dep,confs[i]);
      }
      confs=dep.getConfsToFetch();
      for (int i=0; i < confs.length; i++) {
        fetchDependencies(dep,confs[i]);
      }
    }
  }
}
Program: 82778
Project: 82778
Buggy source:
public File getDefaultIvyUserDir(){
  if (_defaultUserDir == null) {
    _defaultUserDir=new File(System.getProperty("String_Node_Str"),"String_Node_Str");
    Message.verbose("String_Node_Str" + _defaultUserDir);
  }
  return _defaultUserDir;
}

Fixed version (ground truth):
public File getDefaultIvyUserDir(){
  if (_defaultUserDir == null) {
    setDefaultIvyUserDir(new File(System.getProperty("String_Node_Str"),"String_Node_Str"));
    Message.verbose("String_Node_Str" + _defaultUserDir);
  }
  return _defaultUserDir;
}
Program: 82779
Project: 82779
Buggy source:
public void configure(URL configurationURL) throws ParseException, IOException {
  Message.info("String_Node_Str" + configurationURL);
  long start=System.currentTimeMillis();
  setConfigurationVariables(configurationURL);
  new XmlIvyConfigurationParser(this).parse(configurationURL);
  setVariable("String_Node_Str",getDefaultIvyUserDir().getAbsolutePath(),false);
  Message.verbose("String_Node_Str" + (System.currentTimeMillis() - start) + "String_Node_Str");
  dumpConfig();
}

Fixed version (ground truth):
public void configure(URL configurationURL) throws ParseException, IOException {
  Message.info("String_Node_Str" + configurationURL);
  long start=System.currentTimeMillis();
  setConfigurationVariables(configurationURL);
  getDefaultIvyUserDir();
  getDefaultCache();
  new XmlIvyConfigurationParser(this).parse(configurationURL);
  setVariable("String_Node_Str",getDefaultIvyUserDir().getAbsolutePath(),false);
  Message.verbose("String_Node_Str" + (System.currentTimeMillis() - start) + "String_Node_Str");
  dumpConfig();
}
Program: 82780
Project: 82780
Buggy source:
public void dumpConfig(){
  super.dumpConfig();
  Message.debug("String_Node_Str");
  for (ListIterator iter=_ivyPatterns.listIterator(); iter.hasNext(); ) {
    String p=(String)iter.next();
    Message.debug("String_Node_Str" + p);
  }
  Message.debug("String_Node_Str");
  for (ListIterator iter=_artifactPatterns.listIterator(); iter.hasNext(); ) {
    String p=(String)iter.next();
    Message.debug("String_Node_Str" + p);
  }
}

Fixed version (ground truth):
public void dumpConfig(){
  super.dumpConfig();
  Message.debug("String_Node_Str" + isM2compatible());
  Message.debug("String_Node_Str");
  for (ListIterator iter=getIvyPatterns().listIterator(); iter.hasNext(); ) {
    String p=(String)iter.next();
    Message.debug("String_Node_Str" + p);
  }
  Message.debug("String_Node_Str");
  for (ListIterator iter=getArtifactPatterns().listIterator(); iter.hasNext(); ) {
    String p=(String)iter.next();
    Message.debug("String_Node_Str" + p);
  }
}
Program: 82781
Project: 82781
Buggy source:
protected void clearIvyAttempts(){
  _ivyattempts.clear();
}

Fixed version (ground truth):
protected void clearIvyAttempts(){
  _ivyattempts.clear();
  clearArtifactAttempts();
}
Program: 82783
Project: 82783
Buggy source:
private ResolvedModuleRevision resolvedRevision(ResolvedModuleRevision mr){
  if (isDual()) {
    return new ResolvedModuleRevisionProxy(mr,this);
  }
 else {
    return mr;
  }
}

Fixed version (ground truth):
private ResolvedModuleRevision resolvedRevision(ResolvedModuleRevision mr){
  if (isDual() && mr != null) {
    return new ResolvedModuleRevisionProxy(mr,this);
  }
 else {
    return mr;
  }
}
Program: 82784
Project: 82784
Buggy source:
private String getWholeIvyPattern(){
  return _ivyroot + _ivypattern;
}

Fixed version (ground truth):
private String getWholeIvyPattern(){
  if (_ivyroot == null || _ivypattern == null) {
    return null;
  }
  return _ivyroot + _ivypattern;
}
Program: 82785
Project: 82785
Buggy source:
private void updateWholeIvyPattern(){
  if (isM2compatible()) {
    List patterns=new ArrayList();
    patterns.add(getWholeIvyPattern());
    patterns.add(getWholeArtPattern());
    setIvyPatterns(patterns);
  }
 else {
    setIvyPatterns(Collections.singletonList(getWholeIvyPattern()));
  }
}

Fixed version (ground truth):
private void updateWholeIvyPattern(){
  if (isM2compatible()) {
    List patterns=new ArrayList();
    if (getWholeIvyPattern() != null) {
      patterns.add(getWholeIvyPattern());
    }
    if (getWholeArtPattern() != null) {
      patterns.add(getWholeArtPattern());
    }
    setIvyPatterns(patterns);
  }
 else {
    setIvyPatterns(Collections.singletonList(getWholeIvyPattern()));
  }
}
Program: 82786
Project: 82786
Buggy source:
public void setM2compatible(boolean m2compatible){
  super.setM2compatible(m2compatible);
  if (isM2compatible()) {
    _artroot="String_Node_Str";
    _artpattern="String_Node_Str";
    ensureIvyConfigured(getIvy());
    updateWholeIvyPattern();
  }
}

Fixed version (ground truth):
public void setM2compatible(boolean m2compatible){
  super.setM2compatible(m2compatible);
  if (isM2compatible()) {
    _artroot="String_Node_Str";
    _artpattern="String_Node_Str";
    ensureIvyConfigured(getIvy());
    updateWholeArtPattern();
  }
}
Program: 82787
Project: 82787
Buggy source:
public ResolvedModuleRevisionProxy(ResolvedModuleRevision mr,DependencyResolver resolver){
  _mr=mr;
  _resolver=resolver;
}

Fixed version (ground truth):
public ResolvedModuleRevisionProxy(ResolvedModuleRevision mr,DependencyResolver resolver){
  if (mr == null) {
    throw new NullPointerException("String_Node_Str");
  }
  if (resolver == null) {
    throw new NullPointerException("String_Node_Str");
  }
  _mr=mr;
  _resolver=resolver;
}
Program: 82792
Project: 82792
Buggy source:
public void startElement(String uri,String localName,String qName,Attributes attributes) throws SAXException {
  _contextStack.push(qName);
  if ("String_Node_Str".equals(qName)) {
    _optional=true;
  }
 else   if ("String_Node_Str".equals(qName)) {
    if (_dd == null) {
      _dd=new DefaultDependencyDescriptor(_md,ModuleRevisionId.newInstance(_organisation,_module,_revision),true,true,true);
      _organisation=null;
      _module=null;
      _revision=null;
    }
  }
}

Fixed version (ground truth):
public void startElement(String uri,String localName,String qName,Attributes attributes) throws SAXException {
  _contextStack.push(qName);
  if ("String_Node_Str".equals(qName)) {
    _optional=true;
  }
 else   if ("String_Node_Str".equals(qName)) {
    if (_dd == null) {
      _dd=new DefaultDependencyDescriptor(_md,ModuleRevisionId.newInstance(_organisation,_module,_revision),true,false,true);
      _organisation=null;
      _module=null;
      _revision=null;
    }
  }
}
Program: 82793
Project: 82793
Buggy source:
/** 
 * Adds the current node to the toKeep collection and then processes the each of the direct dependencies of this node that appear in the moduleIdMap (indicating that the dependency is part of this BuildList)
 * @param node the node to be processed
 * @param toKeep the collection of ModuleDescriptors that should be kept
 * @param moduleIdMap reference mapping of moduleId to ModuleDescriptor that are part of the BuildList
 */
private void processFilterNode(ModuleDescriptor node,Collection toKeep,Map moduleIdMap){
  toKeep.add(node);
  DependencyDescriptor[] deps=node.getDependencies();
  for (int i=0; i < deps.length; i++) {
    ModuleId id=deps[i].getDependencyId();
    if (moduleIdMap.get(id) != null) {
      processFilterNode((ModuleDescriptor)moduleIdMap.get(id),toKeep,moduleIdMap);
    }
  }
}

Fixed version (ground truth):
/** 
 * Adds the current node to the toKeep collection and then processes the each of the direct dependencies of this node that appear in the moduleIdMap (indicating that the dependency is part of this BuildList)
 * @param node the node to be processed
 * @param toKeep the set of ModuleDescriptors that should be kept
 * @param moduleIdMap reference mapping of moduleId to ModuleDescriptor that are part of the BuildList
 */
private void processFilterNode(ModuleDescriptor node,Set toKeep,Map moduleIdMap){
  toKeep.add(node);
  DependencyDescriptor[] deps=node.getDependencies();
  for (int i=0; i < deps.length; i++) {
    ModuleId id=deps[i].getDependencyId();
    if (moduleIdMap.get(id) != null) {
      processFilterNode((ModuleDescriptor)moduleIdMap.get(id),toKeep,moduleIdMap);
    }
  }
}
Program: 82794
Project: 82794
Buggy source:
/** 
 * Returns a collection of ModuleDescriptors that are conatined in the input collection of ModuleDescriptors and upon which the root module depends
 * @param mds input collection of ModuleDescriptors
 * @param rootmd root module
 * @return filtered list of modules
 */
private Collection filterModules(Collection mds,ModuleDescriptor rootmd){
  Map moduleIdMap=new HashMap();
  for (Iterator iter=mds.iterator(); iter.hasNext(); ) {
    ModuleDescriptor md=((ModuleDescriptor)iter.next());
    moduleIdMap.put(md.getModuleRevisionId().getModuleId(),md);
  }
  Collection toKeep=new ArrayList();
  processFilterNode(rootmd,toKeep,moduleIdMap);
  for (Iterator iter=toKeep.iterator(); iter.hasNext(); ) {
    ModuleDescriptor md=((ModuleDescriptor)iter.next());
    Message.verbose("String_Node_Str" + md.getModuleRevisionId().getModuleId().getName());
  }
  return toKeep;
}

Fixed version (ground truth):
/** 
 * Returns a collection of ModuleDescriptors that are conatined in the input collection of ModuleDescriptors and upon which the root module depends
 * @param mds input collection of ModuleDescriptors
 * @param rootmd root module
 * @return filtered list of modules
 */
private Collection filterModules(Collection mds,ModuleDescriptor rootmd){
  Map moduleIdMap=new HashMap();
  for (Iterator iter=mds.iterator(); iter.hasNext(); ) {
    ModuleDescriptor md=((ModuleDescriptor)iter.next());
    moduleIdMap.put(md.getModuleRevisionId().getModuleId(),md);
  }
  Set toKeep=new HashSet();
  processFilterNode(rootmd,toKeep,moduleIdMap);
  for (Iterator iter=toKeep.iterator(); iter.hasNext(); ) {
    ModuleDescriptor md=((ModuleDescriptor)iter.next());
    Message.verbose("String_Node_Str" + md.getModuleRevisionId().getModuleId().getName());
  }
  return toKeep;
}
Program: 82795
Project: 82795
Buggy source:
/** 
 * Format the given unit to the given StringBuffer, then return the operator precedence of the outermost operator in the unit expression that was formatted. See   {@link ConverterFormat} for the constants that define thevarious precedence values.
 * @param unit the unit to be formatted
 * @param buffer the <code>StringBuffer</code> to be written to
 * @return the operator precedence of the outermost operator in the unitexpression that was output
 */
@SuppressWarnings({"String_Node_Str","String_Node_Str"}) private int formatInternal(Unit<?> unit,Appendable buffer) throws IOException {
  if (unit instanceof AnnotatedUnit<?>) {
    unit=((AnnotatedUnit<?>)unit).getActualUnit();
  }
  final String symbol=symbolMap.getSymbol(unit);
  if (symbol != null) {
    return noopPrecedenceInternal(buffer,symbol);
  }
 else   if (unit.getProductUnits() != null) {
    return productPrecedenceInternal(unit,buffer);
  }
 else   if (unit instanceof BaseUnit<?>) {
    return noopPrecedenceInternal(buffer,((BaseUnit<?>)unit).getSymbol());
  }
 else   if (unit.getSymbol() != null) {
    return noopPrecedenceInternal(buffer,unit.getSymbol());
  }
 else {
    return newUnitPrecedenceInternal(unit,buffer);
  }
}

Fixed version (ground truth):
/** 
 * Format the given unit to the given StringBuffer, then return the operator precedence of the outermost operator in the unit expression that was formatted. See   {@link ConverterFormat} for the constants that define thevarious precedence values.
 * @param unit the unit to be formatted
 * @param buffer the <code>StringBuffer</code> to be written to
 * @return the operator precedence of the outermost operator in the unitexpression that was output
 */
@SuppressWarnings({"String_Node_Str","String_Node_Str"}) private int formatInternal(Unit<?> unit,Appendable buffer) throws IOException {
  return InternalFormater.INSTANCE.formatInternal(unit,buffer,symbolMap);
}
Program: 82796
Project: 82796
Buggy source:
@SuppressWarnings("String_Node_Str") public Measurement<T,Number> inverse(){
  return new IntegerMeasurement(value,getUnit().inverse());
}

Fixed version (ground truth):
public Measurement<T,Number> inverse(){
  return new IntegerMeasurement(value,getUnit().inverse());
}
Program: 82797
Project: 82797
Buggy source:
public AbstractQuantity<?> parse(CharSequence csq) throws ParserException {
  return parse(csq,new ParsePosition(0));
}

Fixed version (ground truth):
@Override public AbstractQuantity<?> parse(CharSequence csq) throws ParserException {
  return parse(csq,new ParsePosition(0));
}
Program: 82798
Project: 82798
Buggy source:
@Test public void toTest(){
  Quantity metre=AbstractQuantity.of(10,SI.METRE);
  Quantity foot=metre.to(US.FOOT);
  BigDecimal value=(BigDecimal)foot.getValue();
  value.setScale(4,RoundingMode.HALF_EVEN);
  BigDecimal expected=BigDecimal.valueOf(32.8084);
  Assert.assertEquals(expected,value.setScale(4,RoundingMode.HALF_EVEN));
}

Fixed version (ground truth):
@Test public void toTest(){
  Length metre=(Length)AbstractQuantity.of(10,SI.METRE);
  Length foot=(Length)metre.to(US.FOOT);
  BigDecimal value=(BigDecimal)foot.getValue();
  value.setScale(4,RoundingMode.HALF_EVEN);
  BigDecimal expected=BigDecimal.valueOf(32.8084);
  Assert.assertEquals(expected,value.setScale(4,RoundingMode.HALF_EVEN));
}
Program: 82799
Project: 82799
Buggy source:
@Test public void toTest(){
  Length metre=(Length)AbstractQuantity.of(10,SI.METRE);
  Length foot=(Length)metre.to(US.FOOT);
  BigDecimal value=(BigDecimal)foot.getValue();
  value.setScale(4,RoundingMode.HALF_EVEN);
  BigDecimal expected=BigDecimal.valueOf(32.8084);
  Assert.assertEquals(expected,value.setScale(4,RoundingMode.HALF_EVEN));
}

Fixed version (ground truth):
@Test public void toTest(){
  Quantity<Length> metre=AbstractQuantity.of(10,SI.METRE);
  Quantity<Length> foot=(Quantity<Length>)metre.to(US.FOOT);
  BigDecimal value=(BigDecimal)foot.getValue();
  value.setScale(4,RoundingMode.HALF_EVEN);
  BigDecimal expected=BigDecimal.valueOf(32.8084);
  Assert.assertEquals(expected,value.setScale(4,RoundingMode.HALF_EVEN));
}
Program: 82800
Project: 82800
Buggy source:
/** 
 * Returns the measurement numeric value.
 * @return the measurement value.
 */
public abstract Number getValue();

Fixed version (ground truth):
/** 
 * Returns the measurement numeric value.
 * @return the measurement value.
 */
@Override public abstract Number getValue();
Program: 82801
Project: 82801
Buggy source:
/** 
 * Returns the measurement unit.
 * @return the measurement unit.
 */
public Unit<Q> getUnit(){
  return unit;
}

Fixed version (ground truth):
/** 
 * Returns the measurement unit.
 * @return the measurement unit.
 */
@Override public Unit<Q> getUnit(){
  return unit;
}
Program: 82802
Project: 82802
Buggy source:
@Override public boolean equals(Object obj){
  if (this == obj) {
    return true;
  }
  if (obj instanceof ProductUnit<?>) {
    Element[] elems=((ProductUnit<?>)obj).elements;
    return Arrays.equals(elements,elems);
  }
  return false;
}

Fixed version (ground truth):
@Override public boolean equals(Object obj){
  if (this == obj) {
    return true;
  }
  if (obj instanceof ProductUnit<?>) {
    Element[] elems=((ProductUnit<?>)obj).elements;
    if (elements.length != elems.length)     return false;
    for (    Element element : elements) {
      boolean unitFound=false;
      Element e=element;
      for (      Element elem : elems) {
        if (e.unit.equals(elem.unit))         if ((e.pow != elem.pow) || (e.root != elem.root))         return false;
 else {
          unitFound=true;
          break;
        }
      }
      if (!unitFound)       return false;
    }
    return true;
  }
  return false;
}
Program: 82803
Project: 82803
Buggy source:
@Test public void testGetJsonWithResources() throws NoSuchFieldException, ClassNotFoundException {
  IdsHelper.loadValues(R.class);
  String s=IdsHelper.toJson(Robolectric.application.getResources());
  HashMap hashMap=new Gson().fromJson(s,HashMap.class);
  List<LinkedTreeMap> list=(List<LinkedTreeMap>)hashMap.get("String_Node_Str");
  boolean hasSource=false;
  for (  LinkedTreeMap v : list) {
    assertNotNull(v.get("String_Node_Str"));
    assertNotNull(v.get("String_Node_Str"));
    hasSource|=v.containsKey("String_Node_Str");
  }
  assertTrue(hasSource);
}

Fixed version (ground truth):
@Test public void testGetJsonWithResources() throws NoSuchFieldException, ClassNotFoundException {
  IdsHelper.loadValues(com.scurab.android.anuitorsample.R.class);
  String s=IdsHelper.toJson(Robolectric.application.getResources());
  HashMap hashMap=new Gson().fromJson(s,HashMap.class);
  List<LinkedTreeMap> list=(List<LinkedTreeMap>)hashMap.get("String_Node_Str");
  boolean hasSource=false;
  for (  LinkedTreeMap v : list) {
    assertNotNull(v.get("String_Node_Str"));
    assertNotNull(v.get("String_Node_Str"));
    hasSource|=v.containsKey("String_Node_Str");
  }
  assertTrue(hasSource);
}
Program: 82804
Project: 82804
Buggy source:
@Override public void onValueChange(ValueChangeEvent<String> event){
  if (event.getValue().length() == 0) {
    openScreen("String_Node_Str");
  }
}

Fixed version (ground truth):
@Override public void onValueChange(ValueChangeEvent<String> event){
  PBarHelper.hide();
  openScreen(event.getValue());
}
Program: 82805
Project: 82805
Buggy source:
/** 
 * This is the entry point method.
 */
@Override public void onModuleLoad(){
  History.addValueChangeHandler(new ValueChangeHandler<String>(){
    @Override public void onValueChange(    ValueChangeEvent<String> event){
      if (event.getValue().length() == 0) {
        openScreen("String_Node_Str");
      }
    }
  }
);
  openScreen(History.getToken());
}

Fixed version (ground truth):
/** 
 * This is the entry point method.
 */
@Override public void onModuleLoad(){
  History.addValueChangeHandler(new ValueChangeHandler<String>(){
    @Override public void onValueChange(    ValueChangeEvent<String> event){
      PBarHelper.hide();
      openScreen(event.getValue());
    }
  }
);
  openScreen(History.getToken());
}
Program: 82806
Project: 82806
Buggy source:
@Override public HashMap<String,Object> fillValues(View v,HashMap<String,Object> data,HashMap<String,Object> parentData){
  super.fillValues(v,data,parentData);
  SeekBar sb=(SeekBar)v;
  data.put("String_Node_Str",sb.getThumbOffset());
  return data;
}

Fixed version (ground truth):
@Override public HashMap<String,Object> fillValues(View v,HashMap<String,Object> data,HashMap<String,Object> parentData){
  super.fillValues(v,data,parentData);
  AbsSeekBar sb=(AbsSeekBar)v;
  data.put("String_Node_Str",sb.getThumbOffset());
  return data;
}
Program: 82808
Project: 82808
Buggy source:
public Template(DyvilCompiler compiler,Package pack,File input,File output){
  super(compiler,pack,input,output);
  this.markers=new MarkerList(I18n.INSTANCE);
}

Fixed version (ground truth):
public Template(DyvilCompiler compiler,Package pack,File input,File output){
  super(compiler,pack,input,output);
  this.markers=new MarkerList(I18n.SYNTAX);
}
Program: 82809
Project: 82809
Buggy source:
public ScopeDirective(){
}

Fixed version (ground truth):
public ScopeDirective(){
  this.value=new StringInterpolationExpr();
}
Program: 82810
Project: 82810
Buggy source:
@Override public void writeExpression(MethodWriter writer,IType type) throws BytecodeException {
  super.writeExpression(writer,type);
  if (this.block != null) {
    this.block.writeExpression(writer,Types.VOID);
  }
}

Fixed version (ground truth):
@Override public void writeExpression(MethodWriter writer,IType type) throws BytecodeException {
  if (this.getValue() != null) {
    super.writeExpression(writer,type);
  }
  if (this.block != null) {
    this.block.writeExpression(writer,Types.VOID);
  }
}
Program: 82811
Project: 82811
Buggy source:
private void parseDyvilArguments(){
  final DyvilLexer sublexer=new DyvilLexer(this.markers,GenSrcSymbols.INSTANCE);
  sublexer.setInterpolationEnd();
  this.useSubLexer(sublexer);
}

Fixed version (ground truth):
private void parseDyvilArguments(){
  final DyvilLexer sublexer=new DyvilLexer(this.markers,DyvilSymbols.INSTANCE);
  sublexer.setInterpolationEnd();
  this.useSubLexer(sublexer);
}
Program: 82812
Project: 82812
Buggy source:
@Override public void parse(IParserManager pm,IToken token){
  final int type=token.type();
switch (this.mode) {
case ELEMENT:
switch (type) {
case BaseSymbols.CLOSE_CURLY_BRACKET:
      pm.popParser(true);
    return;
case Tokens.EOF:
  return;
case Tokens.STRING:
this.directives.add(new ProcessedText(token.stringValue()));
return;
case BaseSymbols.HASH:
this.mode=DIRECTIVE_NAME;
return;
}
return;
case DIRECTIVE_NAME:
switch (type) {
case GenSrcSymbols.TEMPLATE:
pm.pushParser(new TemplateDirectiveParser(this.template),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.IMPORT:
pm.pushParser(new ImportDirectiveParser(this.template),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.IF:
pm.pushParser(new IfDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.FOR:
pm.pushParser(new ForDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.VAR:
case GenSrcSymbols.LET:
case GenSrcSymbols.CONST:
pm.pushParser(new VarDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.FUNC:
pm.pushParser(new FuncDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case BaseSymbols.OPEN_PARENTHESIS:
case BaseSymbols.OPEN_CURLY_BRACKET:
pm.pushParser(new ScopeDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
}
if (Tokens.isIdentifier(type)) {
pm.pushParser(new CallDirectiveParser(this.directives),true);
return;
}
pm.report(token,"String_Node_Str");
}
}

Fixed version (ground truth):
@Override public void parse(IParserManager pm,IToken token){
  final int type=token.type();
switch (this.mode) {
case ELEMENT:
switch (type) {
case BaseSymbols.CLOSE_CURLY_BRACKET:
      pm.popParser(true);
    return;
case Tokens.EOF:
  return;
case Tokens.STRING:
this.directives.add(new ProcessedText(token.stringValue()));
return;
case BaseSymbols.HASH:
this.mode=DIRECTIVE_NAME;
return;
}
return;
case DIRECTIVE_NAME:
switch (type) {
case GenSrcSymbols.TEMPLATE:
pm.pushParser(new TemplateDirectiveParser(this.template),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.IMPORT:
pm.pushParser(new ImportDirectiveParser(this.template),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.IF:
pm.pushParser(new IfDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.FOR:
pm.pushParser(new ForDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.VAR:
case GenSrcSymbols.LET:
case GenSrcSymbols.CONST:
pm.pushParser(new VarDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case GenSrcSymbols.FUNC:
pm.pushParser(new FuncDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
case BaseSymbols.OPEN_PARENTHESIS:
case BaseSymbols.OPEN_CURLY_BRACKET:
pm.pushParser(new ScopeDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
}
if (Tokens.isIdentifier(type)) {
pm.pushParser(new CallDirectiveParser(this.directives),true);
this.mode=ELEMENT;
return;
}
pm.report(token,"String_Node_Str");
}
}
Program: 82813
Project: 82813
Buggy source:
public static <T extends Enum<T>>T getEnumValue(ArgumentList arguments,IParameter parameter,Class<T> type){
  IValue value=arguments.get(parameter);
  if (value == null) {
    value=parameter.getValue();
  }
switch (value.valueTag()) {
case IValue.ENUM_ACCESS:
    return Enum.valueOf(type,((EnumValue)value).getInternalName());
case IValue.FIELD_ACCESS:
  if (Types.isSameType(parameter.getCovariantType(),value.getType())) {
    return Enum.valueOf(type,((FieldAccess)value).getName().qualified);
  }
break;
}
return null;
}

Fixed version (ground truth):
public static <T extends Enum<T>>T getEnumValue(ArgumentList arguments,IParameter parameter,Class<T> type){
  IValue value=arguments.get(parameter);
  if (value == null) {
    value=parameter.getValue();
  }
  try {
switch (value.valueTag()) {
case IValue.ENUM_ACCESS:
      return Enum.valueOf(type,((EnumValue)value).getInternalName());
case IValue.FIELD_ACCESS:
    if (Types.isSameType(parameter.getCovariantType(),value.getType())) {
      return Enum.valueOf(type,((FieldAccess)value).getName().qualified);
    }
}
}
 catch (IllegalArgumentException ignored) {
}
return null;
}
Program: 82814
Project: 82814
Buggy source:
public static String getStringValue(ArgumentList arguments,IParameter parameter){
  IValue value=arguments.get(parameter);
  if (value == null) {
    value=parameter.getValue();
  }
  if (value.valueTag() == IValue.STRING) {
    return value.stringValue();
  }
  return null;
}

Fixed version (ground truth):
public static String getStringValue(ArgumentList arguments,IParameter parameter){
  IValue value=arguments.get(parameter);
  if (value == null) {
    value=parameter.getValue();
  }
  return value.stringValue();
}
Program: 82815
Project: 82815
Buggy source:
private static String replaceMember(IMember member,String value){
  return value.replace("String_Node_Str",Markers.getSemantic("String_Node_Str" + member.getKind().getName())).replace("String_Node_Str",member.getName().toString());
}

Fixed version (ground truth):
private static String replaceMember(IMember member,String value){
  if (value == null) {
    return null;
  }
  return value.replace("String_Node_Str",Markers.getSemantic("String_Node_Str" + member.getKind().getName())).replace("String_Node_Str",member.getName().toString());
}
Program: 82816
Project: 82816
Buggy source:
@Override public boolean isResolved(){
  return this.method != null;
}

Fixed version (ground truth):
@Override public boolean isResolved(){
  return this.method != null && this.method.getType().isResolved();
}
Program: 82817
Project: 82817
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  if (this.receiver != null) {
    this.receiver.check(markers,context);
  }
  if (this.method != null) {
    this.method.checkCall(markers,this.position,context,this.receiver,this.arguments,this.getGenericData());
  }
  this.arguments.check(markers,context);
  if (this.genericData != null) {
    this.genericData.check(markers,context);
  }
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  if (this.receiver != null) {
    this.receiver.check(markers,context);
  }
  if (this.method != null) {
    this.method.checkCall(markers,this.position,context,this.receiver,this.arguments,this.getGenericData());
    if (!this.method.getType().isResolved()) {
      markers.add(Markers.semanticError(this.position,"String_Node_Str",this.getName()));
    }
  }
  this.arguments.check(markers,context);
  if (this.genericData != null) {
    this.genericData.check(markers,context);
  }
}
Program: 82818
Project: 82818
Buggy source:
@Override public boolean isResolved(){
  return this.field != null;
}

Fixed version (ground truth):
@Override public boolean isResolved(){
  return this.field != null && this.field.getType().isResolved();
}
Program: 82819
Project: 82819
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  if (this.receiver != null) {
    this.receiver.check(markers,context);
  }
  if (this.value != null) {
    this.value.check(markers,context);
  }
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  super.check(markers,context);
  if (this.value != null) {
    this.value.check(markers,context);
  }
}
Program: 82820
Project: 82820
Buggy source:
@Override public void resolveTypes(MarkerList markers,IContext context){
  if (this.receiver != null) {
    this.receiver.resolveTypes(markers,context);
  }
  if (this.value != null) {
    this.value.resolveTypes(markers,context);
  }
}

Fixed version (ground truth):
@Override public void resolveTypes(MarkerList markers,IContext context){
  super.resolveTypes(markers,context);
  if (this.value != null) {
    this.value.resolveTypes(markers,context);
  }
}
Program: 82822
Project: 82822
Buggy source:
protected void writeArguments(MethodWriter writer,IValue receiver,ArgumentList arguments) throws BytecodeException {
  if (receiver != null && !receiver.isIgnoredClassAccess() && this.hasModifier(Modifiers.INFIX)) {
    arguments.writeValues(writer,this.parameters,1);
    return;
  }
  arguments.writeValues(writer,this.parameters,0);
}

Fixed version (ground truth):
protected void writeArguments(MethodWriter writer,IValue receiver,ArgumentList arguments) throws BytecodeException {
  if (receiver != null && !receiver.isIgnoredClassAccess() && this.hasModifier(Modifiers.INFIX) && !this.parameters.isEmpty()) {
    arguments.writeValues(writer,this.parameters,1);
    return;
  }
  arguments.writeValues(writer,this.parameters,0);
}
Program: 82823
Project: 82823
Buggy source:
protected void writeReceiver(MethodWriter writer,IValue receiver) throws BytecodeException {
  if (receiver == null) {
    return;
  }
  final int modifiers=this.attributes.flags();
  if ((modifiers & Modifiers.INFIX) == Modifiers.INFIX) {
    receiver.writeExpression(writer,this.parameters.get(0).getCovariantType());
    return;
  }
  final IType receiverType=this.enclosingClass.getReceiverType();
  if ((modifiers & Modifiers.STATIC) == 0) {
    receiver.writeNullCheckedExpression(writer,receiverType);
  }
 else {
    receiver.writeExpression(writer,receiverType);
  }
  if (receiver.isIgnoredClassAccess()) {
    final IType type=receiver.getType();
    if (type.hasTag(IType.TYPE_VAR)) {
      type.writeClassExpression(writer,true);
    }
  }
}

Fixed version (ground truth):
protected void writeReceiver(MethodWriter writer,IValue receiver) throws BytecodeException {
  if (receiver == null) {
    return;
  }
  if (this.hasModifier(Modifiers.INFIX) && !this.parameters.isEmpty()) {
    receiver.writeExpression(writer,this.parameters.get(0).getCovariantType());
    return;
  }
  final IType receiverType=this.enclosingClass.getReceiverType();
  if (!this.isStatic()) {
    receiver.writeNullCheckedExpression(writer,receiverType);
  }
 else {
    receiver.writeExpression(writer,receiverType);
  }
  if (receiver.isIgnoredClassAccess()) {
    final IType type=receiver.getType();
    if (type.hasTag(IType.TYPE_VAR)) {
      type.writeClassExpression(writer,true);
    }
  }
}
Program: 82825
Project: 82825
Buggy source:
@Override public void writeExpression(MethodWriter writer,IType type) throws BytecodeException {
}

Fixed version (ground truth):
@Override public void writeExpression(MethodWriter writer,IType type) throws BytecodeException {
  if (this.writer != null) {
    this.writer.accept(writer,type);
  }
}
Program: 82827
Project: 82827
Buggy source:
protected static IValue resolveMissing(IParameter param,GenericData genericData,SourcePosition position,MarkerList markers,IContext context){
  if (param.isVarargs()) {
    return convertValue(new ArrayExpr(position,EMPTY),param,genericData,markers,context);
  }
  if (param.hasModifier(Modifiers.IMPLICIT)) {
    final IValue implicit=context.resolveImplicit(param.getCovariantType());
    if (implicit != null) {
      return implicit;
    }
  }
  if (param.isDefault()) {
    return new DummyValue(param.getCovariantType(),(writer,type) -> param.writeGetDefaultValue(writer));
  }
  return null;
}

Fixed version (ground truth):
protected static IValue resolveMissing(IParameter param,GenericData genericData,SourcePosition position,MarkerList markers,IContext context){
  if (param.isVarargs()) {
    return convertValue(new ArrayExpr(position,EMPTY),param,genericData,markers,context);
  }
  if (param.isImplicit()) {
    final IValue implicit=context.resolveImplicit(param.getCovariantType().getConcreteType(genericData));
    if (implicit != null) {
      return implicit;
    }
  }
  if (param.isDefault()) {
    return new DummyValue(param.getCovariantType(),(writer,type) -> param.writeGetDefaultValue(writer));
  }
  return null;
}
Program: 82828
Project: 82828
Buggy source:
@Override public IValue resolveImplicit(IType type){
  return type == null ? this.implicitValue : null;
}

Fixed version (ground truth):
@Override public IValue resolveImplicit(IType type){
  return type == null ? this.implicitValue : super.resolveImplicit(type);
}
Program: 82829
Project: 82829
Buggy source:
private void readTargets(){
  final IAnnotation target=this.theClass.getAnnotation(Annotation.LazyFields.TARGET_CLASS);
  if (target == null) {
    return;
  }
  this.targets=EnumSet.noneOf(ElementType.class);
  final ArrayExpr arrayExpr=(ArrayExpr)target.getArguments().get(0,Names.value);
  if (arrayExpr == null) {
    return;
  }
  final ArgumentList values=arrayExpr.getValues();
  final int size=values.size();
  for (int i=0; i < size; i++) {
    final INamed value=(INamed)values.get(i);
    try {
      this.targets.add(ElementType.valueOf(value.getName().qualified));
    }
 catch (    IllegalArgumentException ignored) {
    }
  }
}

Fixed version (ground truth):
private void readTargets(){
  final IAnnotation target=this.theClass.getAnnotation(Annotation.LazyFields.TARGET_CLASS);
  if (target == null) {
    return;
  }
  this.targets=EnumSet.noneOf(ElementType.class);
  final IValue argument=target.getArguments().get(0,Names.value);
  if (!(argument instanceof ArrayExpr)) {
    return;
  }
  final ArgumentList values=((ArrayExpr)argument).getValues();
  final int size=values.size();
  for (int i=0; i < size; i++) {
    final INamed value=(INamed)values.get(i);
    try {
      this.targets.add(ElementType.valueOf(value.getName().qualified));
    }
 catch (    IllegalArgumentException ignored) {
    }
  }
}
Program: 82830
Project: 82830
Buggy source:
@Override public void resolveTypesGenerate(MarkerList markers,IContext context){
  final ClassBody body=this.theClass.getBody();
  final IType classType=this.theClass.getClassType();
  final IType arrayType=new ArrayType(classType,Mutability.IMMUTABLE);
  this.initValuesField(body,arrayType);
  this.initValuesMethod(classType,arrayType);
  this.updateConstructors(classType);
}

Fixed version (ground truth):
@Override public void resolveTypesGenerate(MarkerList markers,IContext context){
  final ClassBody body=this.theClass.getBody();
  final IType classType=this.theClass.getClassType();
  final IType arrayType=new ArrayType(classType,Mutability.IMMUTABLE);
  this.initValuesField(body,arrayType);
  this.initValuesMethod(arrayType);
  this.updateConstructors(classType);
}
Program: 82831
Project: 82831
Buggy source:
protected void initValuesMethod(IType classType,IType arrayType){
  this.valuesMethod=new CodeMethod(this.theClass,Names.values,arrayType,new FlagModifierSet(Modifiers.PUBLIC | Modifiers.STATIC));
  final IValue valuesFieldAccess=new FieldAccess(this.valuesField);
  final IMethod cloneMethod=IContext.resolveMethod(arrayType,valuesFieldAccess,Name.fromRaw("String_Node_Str"),ArgumentList.EMPTY);
  final MethodCall cloneCall=new MethodCall(null,valuesFieldAccess,cloneMethod,ArgumentList.EMPTY);
  cloneCall.setGenericData(new GenericData(cloneMethod,classType));
  this.valuesMethod.setValue(cloneCall);
}

Fixed version (ground truth):
protected void initValuesMethod(IType arrayType){
  this.valuesMethod=new CodeMethod(this.theClass,Names.values,arrayType,new FlagModifierSet(Modifiers.PUBLIC | Modifiers.STATIC));
}
Program: 82832
Project: 82832
Buggy source:
@Override public void addOverride(IMethod method){
}

Fixed version (ground truth):
@Override public void addOverride(IMethod method){
  if (!this.enclosingClass.isSubClassOf(method.getEnclosingClass().getClassType())) {
    return;
  }
  if (this.overrideMethods == null) {
    this.overrideMethods=new IdentityHashSet<>();
  }
  this.overrideMethods.add(method);
}
Program: 82833
Project: 82833
Buggy source:
@Override public boolean overrides(IMethod candidate,ITypeContext typeContext){
  if (candidate.getName() != this.name || this.typeArity() != candidate.typeArity() || candidate.hasModifier(Modifiers.STATIC_FINAL)) {
    return false;
  }
  final ParameterList candidateParameters=candidate.getParameters();
  if (candidateParameters.size() != this.parameters.size()) {
    return false;
  }
  if (this.checkOverride0(candidate)) {
    return true;
  }
  for (int i=0, count=this.parameters.size(); i < count; i++) {
    final IType parType=this.parameters.get(i).getCovariantType().getConcreteType(typeContext);
    final IType candidateParType=candidateParameters.get(i).getCovariantType().getConcreteType(typeContext);
    if (!Types.isSameType(parType,candidateParType)) {
      return false;
    }
  }
  return true;
}

Fixed version (ground truth):
@Override public boolean overrides(IMethod candidate,ITypeContext typeContext){
  if (candidate.getName() != this.name || this.typeArity() != candidate.typeArity() || candidate.hasModifier(Modifiers.STATIC_FINAL)) {
    return false;
  }
  final ParameterList thisParameters=this.getParameters();
  final ParameterList candidateParameters=candidate.getParameters();
  if (candidateParameters.size() != thisParameters.size()) {
    return false;
  }
  if (this.overrideMethods != null && this.overrideMethods.contains(candidate)) {
    return true;
  }
  for (int i=0, count=thisParameters.size(); i < count; i++) {
    final IType parType=thisParameters.get(i).getCovariantType().getConcreteType(typeContext);
    final IType candidateParType=candidateParameters.get(i).getCovariantType().getConcreteType(typeContext);
    if (!Types.isSameType(parType,candidateParType)) {
      return false;
    }
  }
  return true;
}
Program: 82834
Project: 82834
Buggy source:
@Override public void writeAnnotations(TypeAnnotatableVisitor visitor,int typeRef,String typePath){
  this.type.writeAnnotations(visitor,typeRef,typePath + '*');
}

Fixed version (ground truth):
@Override public void writeAnnotations(TypeAnnotatableVisitor visitor,int typeRef,String typePath){
  IType.writeAnnotations(this.type,visitor,typeRef,typePath + '*');
}
Program: 82835
Project: 82835
Buggy source:
private void printMarkers(GenSrc gensrc,MarkerList markers,Specialization spec){
  final StringBuilder builder=new StringBuilder();
  if (spec == null) {
    builder.append(I18n.get("String_Node_Str",this.sourceFile.getInputFile()));
  }
 else {
    builder.append(I18n.get("String_Node_Str",this.sourceFile.getInputFile(),spec.getFileName()));
  }
  builder.append('\n').append('\n');
  final boolean colors=gensrc.useAnsiColors();
  for (  Marker marker : markers) {
    marker.log(this.sourceFile,builder,colors);
  }
  gensrc.getOutput().println(builder);
}

Fixed version (ground truth):
private void printMarkers(GenSrc gensrc,MarkerList markers,Specialization spec){
  final StringBuilder builder=new StringBuilder();
  if (spec == null) {
    builder.append(I18n.get("String_Node_Str",this.sourceFile.getInputFile()));
  }
 else {
    builder.append(I18n.get("String_Node_Str",this.sourceFile.getInputFile(),spec.getFileName()));
  }
  builder.append('\n').append('\n');
  final boolean colors=gensrc.useAnsiColors();
  markers.log(this.sourceFile,builder,colors);
  gensrc.getOutput().println(builder);
}
Program: 82836
Project: 82836
Buggy source:
@Override public void check(MarkerList markers,IContext context){
  this.type.check(markers,context);
  if (!this.type.isResolved()) {
    return;
  }
  this.checkSuperType(markers,context);
}

Fixed version (ground truth):
@Override public void check(MarkerList markers,IContext context){
  this.type.check(markers,context);
}
Program: 82837
Project: 82837
Buggy source:
private void checkSuperType(MarkerList markers,IContext context){
  final IClass superClass=this.type.getTheClass();
  final IClass enclosingClass=context.getThisClass();
  final IType enclosingType=enclosingClass.getClassType();
  final String message;
  boolean indirectSuperInterface=false;
  if (superClass == enclosingClass) {
    message="String_Node_Str";
  }
 else   if (!Types.isSuperType(this.type,enclosingType)) {
    message="String_Node_Str";
  }
 else {
    if (enclosingClass.getSuperType().isSameClass(this.type)) {
      return;
    }
    if (superClass.isInterface()) {
      for (int i=0, count=enclosingClass.interfaceCount(); i < count; i++) {
        if (enclosingClass.getInterface(i).isSameClass(this.type)) {
          return;
        }
      }
      indirectSuperInterface=true;
    }
    message="String_Node_Str";
  }
  final Marker marker=Markers.semanticError(this.type.getPosition(),message);
  if (indirectSuperInterface) {
    marker.addInfo(Markers.getSemantic("String_Node_Str",this.type,enclosingClass.getName()));
  }
  marker.addInfo(Markers.getSemantic("String_Node_Str",enclosingType));
  marker.addInfo(Markers.getSemantic("String_Node_Str",this.type));
  markers.add(marker);
}

Fixed version (ground truth):
private void checkSuperType(MarkerList markers,IContext context){
  final IClass superClass=this.type.getTheClass();
  final IClass enclosingClass=context.getThisClass();
  final IType enclosingType=enclosingClass.getClassType();
  final String message;
  boolean indirectSuperInterface=false;
  if (superClass == enclosingClass) {
    message="String_Node_Str";
  }
 else   if (!Types.isSuperType(this.type,enclosingType)) {
    message="String_Node_Str";
  }
 else {
    final IType superType=enclosingClass.getSuperType();
    if (superType.isSameClass(this.type)) {
      this.type=superType;
      return;
    }
    if (superClass.isInterface()) {
      for (int i=0, count=enclosingClass.interfaceCount(); i < count; i++) {
        final IType interfaceType=enclosingClass.getInterface(i);
        if (interfaceType.isSameClass(this.type)) {
          this.type=interfaceType;
          return;
        }
      }
      indirectSuperInterface=true;
    }
    message="String_Node_Str";
  }
  final Marker marker=Markers.semanticError(this.type.getPosition(),message);
  if (indirectSuperInterface) {
    marker.addInfo(Markers.getSemantic("String_Node_Str",this.type,enclosingClass.getName()));
  }
  marker.addInfo(Markers.getSemantic("String_Node_Str",enclosingType));
  marker.addInfo(Markers.getSemantic("String_Node_Str",this.type));
  markers.add(marker);
}