rem
stringlengths 0
477k
| add
stringlengths 0
313k
| context
stringlengths 6
599k
| meta
stringlengths 141
403
|
---|---|---|---|
IRubyObject javaUtilities = runtime.getClasses().getObjectClass().getConstant("JavaUtilities"); for (int i = 0; i < rubyArgs.length; i++) { IRubyObject obj = rubyArgs[i]; if (obj instanceof JavaObject) { rubyArgs[i] = javaUtilities.callMethod("wrap", new IRubyObject[] { obj, RubyString.newString(runtime, obj.getClass().getName()) }); } } | public Object call(Object recv, String method, Object[] args) throws BSFException { try { IRubyObject rubyRecv = recv != null ? JavaUtil.convertJavaToRuby(runtime, recv) : runtime.getTopSelf(); IRubyObject[] rubyArgs = JavaUtil.convertJavaArrayToRuby(runtime, args); IRubyObject result = rubyRecv.callMethod(method, rubyArgs); return convertToJava(result, Object.class); } catch (Exception excptn) { printException(runtime, excptn); throw new BSFException(BSFException.REASON_EXECUTION_ERROR, excptn.getMessage(), excptn); } } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/6e2b70581b76d19598bc1ec7657fcfece817a53d/JRubyEngine.java/clean/src/org/jruby/javasupport/bsf/JRubyEngine.java |
|
else if (name.equals(FilterWindow.CLOSE_PROPERTY)) | else if (name.equals(FilterWindow.CLOSE_PROPERTY)) { view.onStateChanged(true); | public void propertyChange(PropertyChangeEvent pce) { String name = pce.getPropertyName(); if (name.equals(TreeViewer.FILTER_NODES_PROPERTY)) { Map map = (Map) pce.getNewValue(); if (map.get(model) != null) filterNodes((Set) map.get(model)); } else if (name.equals(FilterMenu.FILTER_SELECTED_PROPERTY)) model.setFilterType(((Integer) pce.getNewValue()).intValue()); else if (name.equals(FilterWindow.CLOSE_PROPERTY)) model.collapse(model.getLastSelectedDisplay()); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/275dac348ef9abda7c33482582699efea0d0ed19/BrowserControl.java/clean/SRC/org/openmicroscopy/shoola/agents/treeviewer/browser/BrowserControl.java |
} | public void propertyChange(PropertyChangeEvent pce) { String name = pce.getPropertyName(); if (name.equals(TreeViewer.FILTER_NODES_PROPERTY)) { Map map = (Map) pce.getNewValue(); if (map.get(model) != null) filterNodes((Set) map.get(model)); } else if (name.equals(FilterMenu.FILTER_SELECTED_PROPERTY)) model.setFilterType(((Integer) pce.getNewValue()).intValue()); else if (name.equals(FilterWindow.CLOSE_PROPERTY)) model.collapse(model.getLastSelectedDisplay()); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/275dac348ef9abda7c33482582699efea0d0ed19/BrowserControl.java/clean/SRC/org/openmicroscopy/shoola/agents/treeviewer/browser/BrowserControl.java |
|
if( methodName!=null || methodDescriptor!=null) | if( methodName!=null && methodDescriptor!=null) | public LineData addLine(int lineNumber, String methodName, String methodDescriptor) { LineData lineData = getLineData(lineNumber); if (lineData == null) { lineData = new LineData(lineNumber); // Each key is a line number in this class, stored as an Integer object. // Each value is information about the line, stored as a LineData object. children.put(new Integer(lineNumber), lineData); } lineData.setMethodNameAndDescriptor(methodName, methodDescriptor); // methodName and methodDescriptor can be null when cobertura.ser with // no line information was loaded (or was not loaded at all). if( methodName!=null || methodDescriptor!=null) methodNamesAndDescriptors.add(methodName + methodDescriptor); return lineData; } | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/94eb278ef0b17d0d807bcec4691a88753492d9f9/ClassData.java/buggy/cobertura/src/net/sourceforge/cobertura/coveragedata/ClassData.java |
Transaction tx = s.beginTransaction(); try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; | try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; } final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); String[][] checks = em.getLockChecks(klass); long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); object.getDetails().setUpdateEvent( updateEvent ); isUnlocked[i] = true; } else { isUnlocked[i] = false; } | public boolean[] unlock(final IObject... iObjects) { // do nothing if possible if (iObjects == null | iObjects.length < 1) return new boolean[] {}; // create a new session. It's important that we pass in the empty // interceptor here, otherwise even root wouldn't be allowed to unlock // the instance. Session s = SessionFactoryUtils.getNewSession(sf, EmptyInterceptor.INSTANCE); Transaction tx = s.beginTransaction(); try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; // do nothing if possible again. if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; } // get the original to operate on final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); // if it's not locked, we don't need to look further. if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } // since it's a managed entity it's class.getName() might // contain // some byte-code generation string final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); // the values that could possibly link to this instance. String[][] checks = em.getLockChecks(klass); // reporting long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); // run the individual queries for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } // reporting if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } // if there are no links, the we can unlock // the actual unlocking happens on flush below. if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); isUnlocked[i] = true; } else { isUnlocked[i] = false; } } return isUnlocked; } finally { s.flush(); tx.commit(); s.close(); } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b2e0d4e007ffb79260681f7450fc94ac7be51414/AdminImpl.java/clean/components/server/src/ome/logic/AdminImpl.java |
final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); String[][] checks = em.getLockChecks(klass); long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); isUnlocked[i] = true; } else { isUnlocked[i] = false; } | return isUnlocked; | public boolean[] unlock(final IObject... iObjects) { // do nothing if possible if (iObjects == null | iObjects.length < 1) return new boolean[] {}; // create a new session. It's important that we pass in the empty // interceptor here, otherwise even root wouldn't be allowed to unlock // the instance. Session s = SessionFactoryUtils.getNewSession(sf, EmptyInterceptor.INSTANCE); Transaction tx = s.beginTransaction(); try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; // do nothing if possible again. if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; } // get the original to operate on final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); // if it's not locked, we don't need to look further. if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } // since it's a managed entity it's class.getName() might // contain // some byte-code generation string final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); // the values that could possibly link to this instance. String[][] checks = em.getLockChecks(klass); // reporting long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); // run the individual queries for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } // reporting if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } // if there are no links, the we can unlock // the actual unlocking happens on flush below. if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); isUnlocked[i] = true; } else { isUnlocked[i] = false; } } return isUnlocked; } finally { s.flush(); tx.commit(); s.close(); } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b2e0d4e007ffb79260681f7450fc94ac7be51414/AdminImpl.java/clean/components/server/src/ome/logic/AdminImpl.java |
return isUnlocked; | finally { s.flush(); s.disconnect(); s.close(); } } finally { getSecuritySystem().enable(UpdateEventListener.UPDATE_EVENT); | public boolean[] unlock(final IObject... iObjects) { // do nothing if possible if (iObjects == null | iObjects.length < 1) return new boolean[] {}; // create a new session. It's important that we pass in the empty // interceptor here, otherwise even root wouldn't be allowed to unlock // the instance. Session s = SessionFactoryUtils.getNewSession(sf, EmptyInterceptor.INSTANCE); Transaction tx = s.beginTransaction(); try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; // do nothing if possible again. if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; } // get the original to operate on final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); // if it's not locked, we don't need to look further. if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } // since it's a managed entity it's class.getName() might // contain // some byte-code generation string final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); // the values that could possibly link to this instance. String[][] checks = em.getLockChecks(klass); // reporting long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); // run the individual queries for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } // reporting if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } // if there are no links, the we can unlock // the actual unlocking happens on flush below. if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); isUnlocked[i] = true; } else { isUnlocked[i] = false; } } return isUnlocked; } finally { s.flush(); tx.commit(); s.close(); } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b2e0d4e007ffb79260681f7450fc94ac7be51414/AdminImpl.java/clean/components/server/src/ome/logic/AdminImpl.java |
finally { s.flush(); tx.commit(); s.close(); } | public boolean[] unlock(final IObject... iObjects) { // do nothing if possible if (iObjects == null | iObjects.length < 1) return new boolean[] {}; // create a new session. It's important that we pass in the empty // interceptor here, otherwise even root wouldn't be allowed to unlock // the instance. Session s = SessionFactoryUtils.getNewSession(sf, EmptyInterceptor.INSTANCE); Transaction tx = s.beginTransaction(); try { boolean[] isUnlocked = new boolean[iObjects.length]; for (int i = 0; i < iObjects.length; i++) { IObject orig = iObjects[i]; // do nothing if possible again. if (orig == null || orig.getId() == null) { isUnlocked[i] = true; continue; } // get the original to operate on final IObject object = (IObject) s.load(orig.getClass(), orig .getId()); // if it's not locked, we don't need to look further. if (!object.getDetails().getPermissions().isSet(Flag.LOCKED)) { isUnlocked[i] = true; continue; } // since it's a managed entity it's class.getName() might // contain // some byte-code generation string final Class<? extends IObject> klass = Utils.trueClass(object .getClass()); final long id = object.getId().longValue(); // the values that could possibly link to this instance. String[][] checks = em.getLockChecks(klass); // reporting long total = 0L; Map<String, Long> counts = new HashMap<String, Long>(); // run the individual queries for (String[] check : checks) { final String hql = String.format( "select count(*) from %s where %s%s = :id ", check[0], check[1], ".id"); org.hibernate.Query q = s.createQuery(hql); q.setLong("id", id); Long count = (Long) q.iterate().next(); if (count != null && count.longValue() > 0) { total += count.longValue(); counts.put(hql, count); } } // reporting if (getLogger().isDebugEnabled()) { getLogger().debug(counts); } // if there are no links, the we can unlock // the actual unlocking happens on flush below. if (total == 0) { object.getDetails().getPermissions().unSet(Flag.LOCKED); isUnlocked[i] = true; } else { isUnlocked[i] = false; } } return isUnlocked; } finally { s.flush(); tx.commit(); s.close(); } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/b2e0d4e007ffb79260681f7450fc94ac7be51414/AdminImpl.java/clean/components/server/src/ome/logic/AdminImpl.java |
|
RubyString src = (RubyString) args[0]; | RubyString src = args[0].convertToString(); | public static IRubyObject eval(IRubyObject recv, IRubyObject[] args) { RubyString src = (RubyString) args[0]; IRubyObject scope = null; String file = "(eval)"; if (args.length > 1) { if (!args[1].isNil()) { scope = args[1]; } if (args.length > 2) { file = args[2].toString(); } } // FIXME: line number is not supported yet //int line = args.length > 3 ? RubyNumeric.fix2int(args[3]) : 1; src.checkSafeString(); ThreadContext context = recv.getRuntime().getCurrentContext(); if (scope == null) { scope = recv.getRuntime().newBinding(); } return recv.evalWithBinding(context, src, scope, file); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/ea4e25f1262c817873877b14c2a82825f1420dd0/RubyKernel.java/clean/src/org/jruby/RubyKernel.java |
RubyString file = (RubyString)args[0]; | RubyString file = args[0].convertToString(); | public static IRubyObject load(IRubyObject recv, IRubyObject[] args) { RubyString file = (RubyString)args[0]; recv.getRuntime().getLoadService().load(file.toString()); return recv.getRuntime().getTrue(); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/ea4e25f1262c817873877b14c2a82825f1420dd0/RubyKernel.java/clean/src/org/jruby/RubyKernel.java |
"RenderingDef with id "+pixelsId+" not found."); | "RenderingDef for Pixels="+pixelsId+" not found."); | public void lookupRenderingDef(long pixelsId) { rwl.writeLock().lock(); try { this.rendDefObj = pixMetaSrv.retrieveRndSettings(pixelsId); this.renderer = null; if ( rendDefObj == null ) throw new ValidationException( "RenderingDef with id "+pixelsId+" not found."); } finally { rwl.writeLock().unlock(); } if (log.isDebugEnabled()) log.debug("lookupRenderingDef for id "+pixelsId+" succeeded: "+this.rendDefObj); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc8dde051a1e2b716514b3964c9222ce006ebea9/RenderingEngineImpl.java/buggy/components/rendering/src/omeis/providers/re/RenderingEngineImpl.java |
log.debug("lookupRenderingDef for id "+pixelsId+" succeeded: "+this.rendDefObj); | log.debug("lookupRenderingDef for Pixels="+pixelsId+" succeeded: "+this.rendDefObj); | public void lookupRenderingDef(long pixelsId) { rwl.writeLock().lock(); try { this.rendDefObj = pixMetaSrv.retrieveRndSettings(pixelsId); this.renderer = null; if ( rendDefObj == null ) throw new ValidationException( "RenderingDef with id "+pixelsId+" not found."); } finally { rwl.writeLock().unlock(); } if (log.isDebugEnabled()) log.debug("lookupRenderingDef for id "+pixelsId+" succeeded: "+this.rendDefObj); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc8dde051a1e2b716514b3964c9222ce006ebea9/RenderingEngineImpl.java/buggy/components/rendering/src/omeis/providers/re/RenderingEngineImpl.java |
this.ctx.applyBeanPropertyValues(this,RenderingEngine.class.getName()); | this.ctx.applyBeanPropertyValues(this,RenderingEngine.class); | public void selfConfigure() { this.ctx = OmeroContext.getInternalServerContext(); this.ctx.applyBeanPropertyValues(this,RenderingEngine.class.getName()); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/dc8dde051a1e2b716514b3964c9222ce006ebea9/RenderingEngineImpl.java/buggy/components/rendering/src/omeis/providers/re/RenderingEngineImpl.java |
if (projectData == null) { System.err.println("Error: Unable to read from data file " + dataFile.getAbsolutePath()); System.exit(1); } | public static void main(String[] args) throws Exception { long startTime = System.currentTimeMillis(); LongOpt[] longOpts = new LongOpt[4]; // TODO: Allow for multiple destination and multiple source directories longOpts[0] = new LongOpt("format", LongOpt.REQUIRED_ARGUMENT, null, 'f'); longOpts[1] = new LongOpt("datafile", LongOpt.REQUIRED_ARGUMENT, null, 'd'); longOpts[2] = new LongOpt("destination", LongOpt.REQUIRED_ARGUMENT, null, 'o'); longOpts[3] = new LongOpt("source", LongOpt.REQUIRED_ARGUMENT, null, 's'); Getopt g = new Getopt(Main.class.getName(), args, ":f:d:o:s:", longOpts); int c; while ((c = g.getopt()) != -1) { switch (c) { case 'f': format = g.getOptarg(); if (!format.equalsIgnoreCase("html") && !format.equalsIgnoreCase("xml")) { System.err .println("Error: format \"" + format + "\" is invalid. Must be either html or xml"); System.exit(1); } break; case 'd': dataFile = new File(g.getOptarg()); if (!dataFile.exists()) { System.err.println("Error: data file " + dataFile.getAbsolutePath() + " does not exist"); System.exit(1); } if (!dataFile.isFile()) { System.err.println("Error: data file " + dataFile.getAbsolutePath() + " must be a regular file"); System.exit(1); } break; case 'o': destinationDir = new File(g.getOptarg()); if (destinationDir.exists() && !destinationDir.isDirectory()) { System.err.println("Error: destination directory " + destinationDir + " already exists but is not a directory"); System.exit(1); } destinationDir.mkdirs(); break; case 's': sourceDir = new File(g.getOptarg()); if (!sourceDir.exists()) { System.err.println("Error: source directory " + sourceDir + " does not exist"); System.exit(1); } if (!sourceDir.isDirectory()) { System.err.println("Error: source directory " + sourceDir + " must be a directory"); System.exit(1); } break; } } if (dataFile == null) dataFile = CoverageDataFileHandler.getDefaultDataFile(); if (destinationDir == null) { System.err.println("Error: destination directory must be set"); System.exit(1); } if (sourceDir == null) { System.err.println("Error: source directory must be set"); System.exit(1); } if (logger.isDebugEnabled()) { logger.debug("format is " + format); logger.debug("dataFile is " + dataFile.getAbsolutePath()); logger.debug("destinationDir is " + destinationDir.getAbsolutePath()); logger.debug("sourceDir is " + sourceDir.getAbsolutePath()); } ProjectData projectData = CoverageDataFileHandler .loadCoverageData(dataFile); if (format.equalsIgnoreCase("html")) { new HTMLReport(projectData, destinationDir, sourceDir); } else if (format.equalsIgnoreCase("xml")) { new XMLReport(projectData, destinationDir, sourceDir); } long stopTime = System.currentTimeMillis(); System.out .println("Reporting time: " + (stopTime - startTime) + "ms"); } | 50197 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50197/1ee130d23185750a6f545220e4718734f717f945/Main.java/clean/cobertura/src/net/sourceforge/cobertura/reporting/Main.java |
|
runtime.getModule("Kernel").callMethod("require",runtime.newString("java")); | public static RubyModule createJRuby(IRuby runtime) { RubyModule comparableModule = runtime.defineModule("JRuby"); CallbackFactory callbackFactory = runtime.callbackFactory(RubyJRuby.class); comparableModule.defineModuleFunction("parse", callbackFactory.getSingletonMethod("parse", IRubyObject.class, IRubyObject.class)); comparableModule.defineModuleFunction("runtime", callbackFactory.getSingletonMethod("runtime")); return comparableModule; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/a73fcf390475dcb40135547d3f6d74fc06bcd08b/RubyJRuby.java/clean/src/org/jruby/RubyJRuby.java |
|
c.add(Restrictions.in("details.id",(Collection) value("annotatorIds"))); | Collection annotatorIds = (Collection) value("annotatorIds"); if (annotatorIds != null && annotatorIds.size() > 0) c.add(Restrictions.in("details.id", annotatorIds )); | protected Object runQuery(Session session) throws HibernateException, SQLException { PojoOptions po = new PojoOptions((Map) value(QP.OPTIONS)); Class target = typeToAnnotationType.get((Class) value(QP.CLASS)); String path = annotationTypeToPath.get(target); Criteria c = session.createCriteria(target); c.createCriteria(path,LEFT_JOIN); c.setResultTransformer(Criteria.DISTINCT_ROOT_ENTITY); c.add(Restrictions.in(path+".id",(Collection) value(QP.IDS))); if (check("annotatorIds")) { c.add(Restrictions.in("details.id",(Collection) value("annotatorIds"))); } return c.list(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/a39e29573bdd486ca5c91592a592b445e6d4625e/PojosFindAnnotationsQueryDefinition.java/clean/components/server/src/ome/services/query/PojosFindAnnotationsQueryDefinition.java |
ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getFullJID()); | ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getNickname()); | public void initialize() { // Listen for right-clicks on ContactItem final ContactList contactList = SparkManager.getWorkspace().getContactList(); final Action listenAction = new AbstractAction() { public void actionPerformed(ActionEvent e) { ContactItem item = (ContactItem)contactList.getSelectedUsers().iterator().next(); contacts.add(item); } }; listenAction.putValue(Action.NAME, Res.getString("menuitem.alert.when.online")); listenAction.putValue(Action.SMALL_ICON, SparkRes.getImageIcon(SparkRes.SMALL_ALARM_CLOCK)); final Action removeAction = new AbstractAction() { public void actionPerformed(ActionEvent e) { ContactItem item = (ContactItem)contactList.getSelectedUsers().iterator().next(); contacts.remove(item); } }; removeAction.putValue(Action.NAME, Res.getString("menuitem.remove.alert.when.online")); removeAction.putValue(Action.SMALL_ICON, SparkRes.getImageIcon(SparkRes.SMALL_DELETE)); contactList.addContextMenuListener(new ContextMenuListener() { public void poppingUp(Object object, JPopupMenu popup) { if (object instanceof ContactItem) { ContactItem item = (ContactItem)object; if (item.getPresence() == null || (item.getPresence().getMode() != Presence.Mode.available && item.getPresence().getMode() != Presence.Mode.chat)) { if (contacts.contains(item)) { popup.add(removeAction); } else { popup.add(listenAction); } } } } public void poppingDown(JPopupMenu popup) { } public boolean handleDefaultAction(MouseEvent e) { return false; } }); // Check presence changes SparkManager.getConnection().addPacketListener(new PacketListener() { public void processPacket(Packet packet) { Presence presence = (Presence)packet; if (presence == null || (presence.getMode() != Presence.Mode.available && presence.getMode() != Presence.Mode.chat)) { return; } String from = presence.getFrom(); final Iterator contactItems = new ArrayList(contacts).iterator(); while (contactItems.hasNext()) { ContactItem item = (ContactItem)contactItems.next(); if (item.getFullJID().equals(StringUtils.parseBareAddress(from))) { contacts.remove(item); ChatManager chatManager = SparkManager.getChatManager(); ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getFullJID()); String time = SparkManager.DATE_SECOND_FORMATTER.format(new Date()); String infoText = Res.getString("message.user.now.available.to.chat", item.getNickname(), time); chatRoom.getTranscriptWindow().insertNotificationMessage(infoText); Message message = new Message(); message.setFrom(item.getFullJID()); message.setBody(infoText); chatManager.getChatContainer().messageReceived(chatRoom, message); } } } }, new PacketTypeFilter(Presence.class)); } | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/f0caeff432cea7ea9181c2a6b312d12998dde960/PresenceChangePlugin.java/clean/src/java/org/jivesoftware/sparkimpl/plugin/chat/PresenceChangePlugin.java |
ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getFullJID()); | ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getNickname()); | public void processPacket(Packet packet) { Presence presence = (Presence)packet; if (presence == null || (presence.getMode() != Presence.Mode.available && presence.getMode() != Presence.Mode.chat)) { return; } String from = presence.getFrom(); final Iterator contactItems = new ArrayList(contacts).iterator(); while (contactItems.hasNext()) { ContactItem item = (ContactItem)contactItems.next(); if (item.getFullJID().equals(StringUtils.parseBareAddress(from))) { contacts.remove(item); ChatManager chatManager = SparkManager.getChatManager(); ChatRoom chatRoom = chatManager.createChatRoom(item.getFullJID(), item.getNickname(), item.getFullJID()); String time = SparkManager.DATE_SECOND_FORMATTER.format(new Date()); String infoText = Res.getString("message.user.now.available.to.chat", item.getNickname(), time); chatRoom.getTranscriptWindow().insertNotificationMessage(infoText); Message message = new Message(); message.setFrom(item.getFullJID()); message.setBody(infoText); chatManager.getChatContainer().messageReceived(chatRoom, message); } } } | 52006 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52006/f0caeff432cea7ea9181c2a6b312d12998dde960/PresenceChangePlugin.java/clean/src/java/org/jivesoftware/sparkimpl/plugin/chat/PresenceChangePlugin.java |
articleBlock.setEditMode(mode); | if(mode!=null){ articleBlock.setEditMode(mode); } | protected void setProperties(UIComponent component) { super.setProperties(component); if (component != null) { ArticleAdminBlock articleBlock = ((ArticleAdminBlock)component); articleBlock.setEditMode(mode); } } | 57000 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57000/7493a23b4d95bba0468c9c8438a4f930b908ebf1/ArticleAdminBlockTag.java/clean/src/java/com/idega/block/article/taglib/ArticleAdminBlockTag.java |
return entry(pos.getValue()); | return entry(pos.getLongValue()); | public RubyObject at(RubyFixnum pos) { return entry(pos.getValue()); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyArray.java/buggy/org/jruby/RubyArray.java |
int lesser = Math.min(len, otherLen); RubyFixnum result = RubyFixnum.zero(getRuby()); for (int i = 0; i < lesser; i++) { result = (RubyFixnum) entry(i).funcall("<=>", ary.entry(i)); if (result.getValue() != 0) { | if (len != otherLen) { return (len > otherLen) ? RubyFixnum.one(getRuby()) : RubyFixnum.minus_one(getRuby()); } for (int i = 0; i < len; i++) { RubyFixnum result = (RubyFixnum) entry(i).funcall("<=>", ary.entry(i)); if (result.getLongValue() != 0) { | public RubyObject op_cmp(RubyObject other) { RubyArray ary = arrayValue(other); int otherLen = ary.getLength(); int len = getLength(); int lesser = Math.min(len, otherLen); RubyFixnum result = RubyFixnum.zero(getRuby()); for (int i = 0; i < lesser; i++) { result = (RubyFixnum) entry(i).funcall("<=>", ary.entry(i)); if (result.getValue() != 0) { return result; } } if (len != otherLen) { return (len > otherLen) ? RubyFixnum.one(getRuby()) : RubyFixnum.minus_one(getRuby()); } return result; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyArray.java/buggy/org/jruby/RubyArray.java |
if (len != otherLen) { return (len > otherLen) ? RubyFixnum.one(getRuby()) : RubyFixnum.minus_one(getRuby()); } return result; | return RubyFixnum.zero(getRuby()); | public RubyObject op_cmp(RubyObject other) { RubyArray ary = arrayValue(other); int otherLen = ary.getLength(); int len = getLength(); int lesser = Math.min(len, otherLen); RubyFixnum result = RubyFixnum.zero(getRuby()); for (int i = 0; i < lesser; i++) { result = (RubyFixnum) entry(i).funcall("<=>", ary.entry(i)); if (result.getValue() != 0) { return result; } } if (len != otherLen) { return (len > otherLen) ? RubyFixnum.one(getRuby()) : RubyFixnum.minus_one(getRuby()); } return result; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyArray.java/buggy/org/jruby/RubyArray.java |
} else if ((args[0] instanceof RubyFixnum) && ((RubyFixnum) args[0]).getValue() < getLength()) { | } else if ((args[0] instanceof RubyFixnum) && (RubyNumeric.fix2long(args[0]) < getLength())) { | public RubyObject slice_bang(RubyObject[] args) { int argc = argCount(args, 1, 2); RubyObject result = aref(args); if (argc == 2) { long beg = RubyNumeric.fix2long(args[0]); long len = RubyNumeric.fix2long(args[1]); replace(beg, len, getRuby().getNil()); } else if ((args[0] instanceof RubyFixnum) && ((RubyFixnum) args[0]).getValue() < getLength()) { replace(RubyNumeric.fix2long(args[0]), 1, getRuby().getNil()); } else if (args[0] instanceof RubyRange) { long[] begLen = ((RubyRange) args[0]).getBeginLength(getLength(), false, true); replace(begLen[0], begLen[1], getRuby().getNil()); } return result; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/786cea08c1dd2092a02d1254b49fbee371ace5f9/RubyArray.java/buggy/org/jruby/RubyArray.java |
int[] inverse = locksFields(type); for (int i = 0; i < inverse.length; i++) { if (klass.equals(type[inverse[i]].getReturnedClass().getName())) | Locks inverse = locksHolder.get(k); for (int i = 0; i < inverse.size(); i++) { if (!inverse.include(i)) continue; if (inverse.hasSubtypes(i)) | private String[][] lockedByFields( String klass, Map<String,ClassMetadata> m ) { if ( m == null ) throw new InternalException( "ClassMetadata map cannot be null." ); List<String[]> fields = new ArrayList<String[]>(); for (String k : m.keySet()) { ClassMetadata cm = m.get( k ); Type[] type = cm.getPropertyTypes(); String[] names = cm.getPropertyNames(); int[] inverse = locksFields(type); for (int i = 0; i < inverse.length; i++) { if (klass.equals(type[inverse[i]].getReturnedClass().getName())) { fields.add(new String[]{k,names[inverse[i]]}); } } } return fields.toArray(new String[fields.size()][2]); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/e30f801c3b2923483e1f69853136328bb21a1d79/ExtendedMetadata.java/clean/components/server/src/ome/tools/hibernate/ExtendedMetadata.java |
fields.add(new String[]{k,names[inverse[i]]}); | for (int j = 0; j < inverse.numberOfSubtypes(i); j++) { if (inverse.subtypeEquals(i, j, klass)) { fields.add(new String[]{k,inverse.subtypeName(i,j)}); } } } else if (klass.equals(type[i].getReturnedClass().getName())) { fields.add(new String[]{k,names[i]}); | private String[][] lockedByFields( String klass, Map<String,ClassMetadata> m ) { if ( m == null ) throw new InternalException( "ClassMetadata map cannot be null." ); List<String[]> fields = new ArrayList<String[]>(); for (String k : m.keySet()) { ClassMetadata cm = m.get( k ); Type[] type = cm.getPropertyTypes(); String[] names = cm.getPropertyNames(); int[] inverse = locksFields(type); for (int i = 0; i < inverse.length; i++) { if (klass.equals(type[inverse[i]].getReturnedClass().getName())) { fields.add(new String[]{k,names[inverse[i]]}); } } } return fields.toArray(new String[fields.size()][2]); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/e30f801c3b2923483e1f69853136328bb21a1d79/ExtendedMetadata.java/clean/components/server/src/ome/tools/hibernate/ExtendedMetadata.java |
ExperimenterGroup group = groupProxy(groupName); | final ExperimenterGroup group = groupProxy(groupName); final EventContext ec = getSecuritySystem().getEventContext(); if ( ! ec.getMemberOfGroupsList().contains(group.getId()) && ! ec.isCurrentUserAdmin() ) throw new SecurityViolation("Cannot change group for:"+iObject); | public void changeGroup(IObject iObject, String groupName) { final LocalUpdate update = iUpdate; // should take a group final IObject copy = iQuery.get(iObject.getClass(), iObject.getId()); ExperimenterGroup group = groupProxy(groupName); copy.getDetails().setGroup(group); getSecuritySystem().doAction(copy, new SecureAction() { public IObject updateObject(IObject obj) { update.flush(); return null; } }); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/96669ca756998116555451076f77a19bb3d1e8df/AdminImpl.java/buggy/components/server/src/ome/logic/AdminImpl.java |
IObject copy = iQuery.get(iObject.getClass(), iObject.getId()); if (!aclVoter.allowChmod(copy)) throw new SecurityViolation("Cannot change permissions for:"+ iObject); copy.getDetails().setPermissions(perms); | copy[0] = iQuery.get(iObject.getClass(), iObject.getId()); } }); if (!aclVoter.allowChmod(copy[0])) throw new SecurityViolation("Cannot change permissions for:"+ copy[0]); getSecuritySystem().runAsAdmin(new AdminAction(){ public void runAsAdmin() { copy[0].getDetails().setPermissions(perms); | public void changePermissions(final IObject iObject, final Permissions perms) { final ACLVoter aclVoter = getSecuritySystem().getACLVoter(); // TODO inject getSecuritySystem().runAsAdmin(new AdminAction(){ public void runAsAdmin() { IObject copy = iQuery.get(iObject.getClass(), iObject.getId()); if (!aclVoter.allowChmod(copy)) throw new SecurityViolation("Cannot change permissions for:"+ iObject); copy.getDetails().setPermissions(perms); iUpdate.flush(); } }); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/96669ca756998116555451076f77a19bb3d1e8df/AdminImpl.java/buggy/components/server/src/ome/logic/AdminImpl.java |
IObject copy = iQuery.get(iObject.getClass(), iObject.getId()); if (!aclVoter.allowChmod(copy)) throw new SecurityViolation("Cannot change permissions for:"+ iObject); copy.getDetails().setPermissions(perms); iUpdate.flush(); | copy[0] = iQuery.get(iObject.getClass(), iObject.getId()); | public void runAsAdmin() { IObject copy = iQuery.get(iObject.getClass(), iObject.getId()); if (!aclVoter.allowChmod(copy)) throw new SecurityViolation("Cannot change permissions for:"+ iObject); copy.getDetails().setPermissions(perms); iUpdate.flush(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/96669ca756998116555451076f77a19bb3d1e8df/AdminImpl.java/buggy/components/server/src/ome/logic/AdminImpl.java |
return Collections.EMPTY_LIST; | return EMPTY_LIST; | public List childNodes() { return Collections.EMPTY_LIST; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/b1293eda8454686e846e2a9837b348e2983bb423/AliasNode.java/clean/src/org/jruby/ast/AliasNode.java |
setResizable(false); | public ColourPicker(Color color) { super(); setTitle("Colour Picker Window"); //setSize(250, 350); setModal(true); // setResizable(false); float[] vals = new float[4]; vals = color.getComponents(vals); model = new RGBModel(vals[0], vals[1], vals[2], vals[3]); RGBControl control = new RGBControl(model); TabbedPaneUI tabbedPane = new TabbedPaneUI(this, control); setLayout(new GridBagLayout()); GridBagConstraints gbc = new GridBagConstraints(); gbc.gridx = 0; gbc.gridy = 0; gbc.weightx = 80; gbc.weighty = 30; gbc.anchor = GridBagConstraints.CENTER; gbc.fill = GridBagConstraints.BOTH; this.getContentPane().add(tabbedPane, gbc); pack(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/a120269806e5dce185dd2b5b26374a782df23119/ColourPicker.java/clean/SRC/org/openmicroscopy/shoola/util/ui/colourpicker/ColourPicker.java |
|
return context.callSuper(context.getFrameArgs()); | return context.callSuper(context.getFrameArgs(), true); | private static IRubyObject evalInternal(ThreadContext context, Node node, IRubyObject self) { IRuby runtime = context.getRuntime(); bigloop: do { if (node == null) return runtime.getNil(); switch (node.nodeId) { case NodeTypes.ALIASNODE: { AliasNode iVisited = (AliasNode) node; if (context.getRubyClass() == null) { throw runtime.newTypeError("no class to make alias"); } context.getRubyClass().defineAlias(iVisited.getNewName(), iVisited.getOldName()); context.getRubyClass().callMethod(context, "method_added", runtime.newSymbol(iVisited.getNewName())); return runtime.getNil(); } case NodeTypes.ANDNODE: { BinaryOperatorNode iVisited = (BinaryOperatorNode) node; IRubyObject result = evalInternal(context, iVisited.getFirstNode(), self); if (!result.isTrue()) return result; node = iVisited.getSecondNode(); continue bigloop; } case NodeTypes.ARGSCATNODE: { ArgsCatNode iVisited = (ArgsCatNode) node; IRubyObject args = evalInternal(context, iVisited.getFirstNode(), self); IRubyObject secondArgs = splatValue(evalInternal(context, iVisited.getSecondNode(), self)); RubyArray list = args instanceof RubyArray ? (RubyArray) args : runtime.newArray(args); return list.concat(secondArgs); } // case NodeTypes.ARGSNODE: // EvaluateVisitor.argsNodeVisitor.execute(this, node); // break; // case NodeTypes.ARGUMENTNODE: // EvaluateVisitor.argumentNodeVisitor.execute(this, node); // break; case NodeTypes.ARRAYNODE: { ArrayNode iVisited = (ArrayNode) node; IRubyObject[] array = new IRubyObject[iVisited.size()]; int i = 0; for (Iterator iterator = iVisited.iterator(); iterator.hasNext();) { Node next = (Node) iterator.next(); array[i++] = evalInternal(context, next, self); } return runtime.newArray(array); } // case NodeTypes.ASSIGNABLENODE: // EvaluateVisitor.assignableNodeVisitor.execute(this, node); // break; case NodeTypes.BACKREFNODE: { BackRefNode iVisited = (BackRefNode) node; IRubyObject backref = context.getBackref(); switch (iVisited.getType()) { case '~': return backref; case '&': return RubyRegexp.last_match(backref); case '`': return RubyRegexp.match_pre(backref); case '\'': return RubyRegexp.match_post(backref); case '+': return RubyRegexp.match_last(backref); } break; } case NodeTypes.BEGINNODE: { BeginNode iVisited = (BeginNode) node; node = iVisited.getBodyNode(); continue bigloop; } case NodeTypes.BIGNUMNODE: { BignumNode iVisited = (BignumNode) node; return RubyBignum.newBignum(runtime, iVisited.getValue()); } // case NodeTypes.BINARYOPERATORNODE: // EvaluateVisitor.binaryOperatorNodeVisitor.execute(this, node); // break; // case NodeTypes.BLOCKARGNODE: // EvaluateVisitor.blockArgNodeVisitor.execute(this, node); // break; case NodeTypes.BLOCKNODE: { BlockNode iVisited = (BlockNode) node; IRubyObject result = runtime.getNil(); for (Iterator iter = iVisited.iterator(); iter.hasNext();) { result = evalInternal(context, (Node) iter.next(), self); } return result; } case NodeTypes.BLOCKPASSNODE: { BlockPassNode iVisited = (BlockPassNode) node; IRubyObject proc = evalInternal(context, iVisited.getBodyNode(), self); if (proc.isNil()) { context.setNoBlock(); try { return evalInternal(context, iVisited.getIterNode(), self); } finally { context.clearNoBlock(); } } // If not already a proc then we should try and make it one. if (!(proc instanceof RubyProc)) { proc = proc.convertToType("Proc", "to_proc", false); if (!(proc instanceof RubyProc)) { throw runtime.newTypeError("wrong argument type " + proc.getMetaClass().getName() + " (expected Proc)"); } } // TODO: Add safety check for taintedness Block block = (Block) context.getCurrentBlock(); if (block != null) { IRubyObject blockObject = block.getBlockObject(); // The current block is already associated with the proc. No need to create new // block for it. Just eval! if (blockObject != null && blockObject == proc) { try { context.setBlockAvailable(); return evalInternal(context, iVisited.getIterNode(), self); } finally { context.clearBlockAvailable(); } } } context.preBlockPassEval(((RubyProc) proc).getBlock()); try { return evalInternal(context, iVisited.getIterNode(), self); } finally { context.postBlockPassEval(); } } case NodeTypes.BREAKNODE: { BreakNode iVisited = (BreakNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); JumpException je = new JumpException(JumpException.JumpType.BreakJump); je.setPrimaryData(result); je.setSecondaryData(node); throw je; } case NodeTypes.CALLNODE: { CallNode iVisited = (CallNode) node; context.beginCallArgs(); IRubyObject receiver = null; IRubyObject[] args = null; try { receiver = evalInternal(context, iVisited.getReceiverNode(), self); args = setupArgs(context, iVisited.getArgsNode(), self); } finally { context.endCallArgs(); } assert receiver.getMetaClass() != null : receiver.getClass().getName(); // If reciever is self then we do the call the same way as vcall CallType callType = (receiver == self ? CallType.VARIABLE : CallType.NORMAL); return receiver.callMethod(context, iVisited.getName(), args, callType); } case NodeTypes.CASENODE: { CaseNode iVisited = (CaseNode) node; IRubyObject expression = null; if (iVisited.getCaseNode() != null) { expression = evalInternal(context, iVisited.getCaseNode(), self); } context.pollThreadEvents(); IRubyObject result = runtime.getNil(); Node firstWhenNode = iVisited.getFirstWhenNode(); while (firstWhenNode != null) { if (!(firstWhenNode instanceof WhenNode)) { node = firstWhenNode; continue bigloop; } WhenNode whenNode = (WhenNode) firstWhenNode; if (whenNode.getExpressionNodes() instanceof ArrayNode) { for (Iterator iter = ((ArrayNode) whenNode.getExpressionNodes()).iterator(); iter .hasNext();) { Node tag = (Node) iter.next(); context.setPosition(tag.getPosition()); if (isTrace(runtime)) { callTraceFunction(context, "line", self); } // Ruby grammar has nested whens in a case body because of // productions case_body and when_args. if (tag instanceof WhenNode) { RubyArray expressions = (RubyArray) evalInternal(context, ((WhenNode) tag) .getExpressionNodes(), self); for (int j = 0; j < expressions.getLength(); j++) { IRubyObject condition = expressions.entry(j); if ((expression != null && condition.callMethod(context, "===", expression) .isTrue()) || (expression == null && condition.isTrue())) { node = ((WhenNode) firstWhenNode).getBodyNode(); continue bigloop; } } continue; } result = evalInternal(context, tag, self); if ((expression != null && result.callMethod(context, "===", expression).isTrue()) || (expression == null && result.isTrue())) { node = whenNode.getBodyNode(); continue bigloop; } } } else { result = evalInternal(context, whenNode.getExpressionNodes(), self); if ((expression != null && result.callMethod(context, "===", expression).isTrue()) || (expression == null && result.isTrue())) { node = ((WhenNode) firstWhenNode).getBodyNode(); continue bigloop; } } context.pollThreadEvents(); firstWhenNode = whenNode.getNextCase(); } return runtime.getNil(); } case NodeTypes.CLASSNODE: { ClassNode iVisited = (ClassNode) node; Node superNode = iVisited.getSuperNode(); RubyClass superClass = superNode == null ? null : (RubyClass) evalInternal(context, superNode, self); Node classNameNode = iVisited.getCPath(); String name = ((INameNode) classNameNode).getName(); RubyModule enclosingClass = getEnclosingModule(context, classNameNode, self); RubyClass rubyClass = enclosingClass.defineOrGetClassUnder(name, superClass); if (context.getWrapper() != null) { rubyClass.extendObject(context.getWrapper()); rubyClass.includeModule(context.getWrapper()); } return evalClassDefinitionBody(context, iVisited.getScope(), iVisited.getBodyNode(), rubyClass, self); } case NodeTypes.CLASSVARASGNNODE: { ClassVarAsgnNode iVisited = (ClassVarAsgnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); RubyModule rubyClass = (RubyModule) context.peekCRef().getValue(); if (rubyClass == null) { rubyClass = self.getMetaClass(); } else if (rubyClass.isSingleton()) { rubyClass = (RubyModule) rubyClass.getInstanceVariable("__attached__"); } rubyClass.setClassVar(iVisited.getName(), result); return result; } case NodeTypes.CLASSVARDECLNODE: { ClassVarDeclNode iVisited = (ClassVarDeclNode) node; // FIXME: shouldn't we use cref here? if (context.getRubyClass() == null) { throw runtime.newTypeError("no class/module to define class variable"); } IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); ((RubyModule) context.peekCRef().getValue()).setClassVar(iVisited.getName(), result); return runtime.getNil(); } case NodeTypes.CLASSVARNODE: { ClassVarNode iVisited = (ClassVarNode) node; RubyModule rubyClass = (RubyModule) context.peekCRef().getValue(); if (rubyClass == null) { rubyClass = self.getMetaClass(); } else if (rubyClass.isSingleton()) { rubyClass = (RubyModule)rubyClass.getInstanceVariable("__attached__"); } return rubyClass.getClassVar(iVisited.getName()); } case NodeTypes.COLON2NODE: { Colon2Node iVisited = (Colon2Node) node; Node leftNode = iVisited.getLeftNode(); // TODO: Made this more colon3 friendly because of cpath production // rule in grammar (it is convenient to think of them as the same thing // at a grammar level even though evaluation is). if (leftNode == null) { return runtime.getObject().getConstantFrom(iVisited.getName()); } else { IRubyObject result = evalInternal(context, iVisited.getLeftNode(), self); if (result instanceof RubyModule) { return ((RubyModule) result).getConstantFrom(iVisited.getName()); } else { return result.callMethod(context, iVisited.getName()); } } } case NodeTypes.COLON3NODE: { Colon3Node iVisited = (Colon3Node) node; return runtime.getObject().getConstantFrom(iVisited.getName()); } case NodeTypes.CONSTDECLNODE: { ConstDeclNode iVisited = (ConstDeclNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); IRubyObject module; if (iVisited.getPathNode() != null) { module = evalInternal(context, iVisited.getPathNode(), self); } else { // FIXME: why do we check RubyClass and then use CRef? if (context.getRubyClass() == null) { // TODO: wire into new exception handling mechanism throw runtime.newTypeError("no class/module to define constant"); } module = (RubyModule) context.peekCRef().getValue(); } // FIXME: shouldn't we use the result of this set in setResult? ((RubyModule) module).setConstant(iVisited.getName(), result); return result; } case NodeTypes.CONSTNODE: { ConstNode iVisited = (ConstNode) node; return context.getConstant(iVisited.getName()); } case NodeTypes.DASGNNODE: { DAsgnNode iVisited = (DAsgnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); // System.out.println("DSetting: " + iVisited.getName() + " at index " + iVisited.getIndex() + " and at depth " + iVisited.getDepth() + " and set " + result); context.getCurrentScope().setValue(iVisited.getIndex(), result, iVisited.getDepth()); return result; } case NodeTypes.DEFINEDNODE: { DefinedNode iVisited = (DefinedNode) node; String definition = getDefinition(context, iVisited.getExpressionNode(), self); if (definition != null) { return runtime.newString(definition); } else { return runtime.getNil(); } } case NodeTypes.DEFNNODE: { DefnNode iVisited = (DefnNode) node; RubyModule containingClass = context.getRubyClass(); if (containingClass == null) { throw runtime.newTypeError("No class to add method."); } String name = iVisited.getName(); if (containingClass == runtime.getObject() && name.equals("initialize")) { runtime.getWarnings().warn("redefining Object#initialize may cause infinite loop"); } Visibility visibility = context.getCurrentVisibility(); if (name.equals("initialize") || visibility.isModuleFunction()) { visibility = Visibility.PRIVATE; } DefaultMethod newMethod = new DefaultMethod(containingClass, iVisited.getScope(), iVisited.getBodyNode(), (ArgsNode) iVisited.getArgsNode(), visibility, context.peekCRef()); if (iVisited.getBodyNode() != null) { iVisited.getBodyNode().accept(new CreateJumpTargetVisitor(newMethod)); } containingClass.addMethod(name, newMethod); if (context.getCurrentVisibility().isModuleFunction()) { containingClass.getSingletonClass().addMethod( name, new WrapperCallable(containingClass.getSingletonClass(), newMethod, Visibility.PUBLIC)); containingClass.callMethod(context, "singleton_method_added", runtime.newSymbol(name)); } // 'class << state.self' and 'class << obj' uses defn as opposed to defs if (containingClass.isSingleton()) { ((MetaClass) containingClass).getAttachedObject().callMethod( context, "singleton_method_added", runtime.newSymbol(iVisited.getName())); } else { containingClass.callMethod(context, "method_added", runtime.newSymbol(name)); } return runtime.getNil(); } case NodeTypes.DEFSNODE: { DefsNode iVisited = (DefsNode) node; IRubyObject receiver = evalInternal(context, iVisited.getReceiverNode(), self); if (runtime.getSafeLevel() >= 4 && !receiver.isTaint()) { throw runtime.newSecurityError("Insecure; can't define singleton method."); } if (receiver.isFrozen()) { throw runtime.newFrozenError("object"); } if (!receiver.singletonMethodsAllowed()) { throw runtime.newTypeError("can't define singleton method \"" + iVisited.getName() + "\" for " + receiver.getType()); } RubyClass rubyClass = receiver.getSingletonClass(); if (runtime.getSafeLevel() >= 4) { ICallable method = (ICallable) rubyClass.getMethods().get(iVisited.getName()); if (method != null) { throw runtime.newSecurityError("Redefining method prohibited."); } } DefaultMethod newMethod = new DefaultMethod(rubyClass, iVisited.getScope(), iVisited.getBodyNode(), (ArgsNode) iVisited.getArgsNode(), Visibility.PUBLIC, context.peekCRef()); if (iVisited.getBodyNode() != null) { iVisited.getBodyNode().accept(new CreateJumpTargetVisitor(newMethod)); } rubyClass.addMethod(iVisited.getName(), newMethod); receiver.callMethod(context, "singleton_method_added", runtime.newSymbol(iVisited.getName())); return runtime.getNil(); } case NodeTypes.DOTNODE: { DotNode iVisited = (DotNode) node; return RubyRange.newRange(runtime, evalInternal(context, iVisited.getBeginNode(), self), evalInternal(context, iVisited .getEndNode(), self), iVisited.isExclusive()); } case NodeTypes.DREGEXPNODE: { DRegexpNode iVisited = (DRegexpNode) node; StringBuffer sb = new StringBuffer(); for (Iterator iterator = iVisited.iterator(); iterator.hasNext();) { Node iterNode = (Node) iterator.next(); sb.append(evalInternal(context, iterNode, self).toString()); } String lang = null; int opts = iVisited.getOptions(); if((opts & 16) != 0) { // param n lang = "n"; } else if((opts & 48) != 0) { // param s lang = "s"; } else if((opts & 64) != 0) { // param s lang = "u"; } return RubyRegexp.newRegexp(runtime, sb.toString(), iVisited.getOptions(), lang); } case NodeTypes.DSTRNODE: { DStrNode iVisited = (DStrNode) node; StringBuffer sb = new StringBuffer(); for (Iterator iterator = iVisited.iterator(); iterator.hasNext();) { Node iterNode = (Node) iterator.next(); sb.append(evalInternal(context, iterNode, self).toString()); } return runtime.newString(sb.toString()); } case NodeTypes.DSYMBOLNODE: { DSymbolNode iVisited = (DSymbolNode) node; StringBuffer sb = new StringBuffer(); for (Iterator iterator = iVisited.getNode().iterator(); iterator.hasNext();) { Node iterNode = (Node) iterator.next(); sb.append(evalInternal(context, iterNode, self).toString()); } return runtime.newSymbol(sb.toString()); } case NodeTypes.DVARNODE: { DVarNode iVisited = (DVarNode) node; // System.out.println("DGetting: " + iVisited.getName() + " at index " + iVisited.getIndex() + " and at depth " + iVisited.getDepth()); IRubyObject obj = context.getCurrentScope().getValue(iVisited.getIndex(), iVisited.getDepth()); // FIXME: null check is removable once we figure out how to assign to unset named block args return obj == null ? runtime.getNil() : obj; } case NodeTypes.DXSTRNODE: { DXStrNode iVisited = (DXStrNode) node; StringBuffer sb = new StringBuffer(); for (Iterator iterator = iVisited.iterator(); iterator.hasNext();) { Node iterNode = (Node) iterator.next(); sb.append(evalInternal(context, iterNode, self).toString()); } return self.callMethod(context, "`", runtime.newString(sb.toString())); } case NodeTypes.ENSURENODE: { EnsureNode iVisited = (EnsureNode) node; // save entering the try if there's nothing to ensure if (iVisited.getEnsureNode() != null) { IRubyObject result = runtime.getNil(); try { result = evalInternal(context, iVisited.getBodyNode(), self); } finally { evalInternal(context, iVisited.getEnsureNode(), self); } return result; } node = iVisited.getBodyNode(); continue bigloop; } case NodeTypes.EVSTRNODE: { EvStrNode iVisited = (EvStrNode) node; node = iVisited.getBody(); continue bigloop; } case NodeTypes.FALSENODE: { context.pollThreadEvents(); return runtime.getFalse(); } case NodeTypes.FCALLNODE: { FCallNode iVisited = (FCallNode) node; context.beginCallArgs(); IRubyObject[] args; try { args = setupArgs(context, iVisited.getArgsNode(), self); } finally { context.endCallArgs(); } return self.callMethod(context, iVisited.getName(), args, CallType.FUNCTIONAL); } case NodeTypes.FIXNUMNODE: { FixnumNode iVisited = (FixnumNode) node; return runtime.newFixnum(iVisited.getValue()); } case NodeTypes.FLIPNODE: { FlipNode iVisited = (FlipNode) node; IRubyObject result = runtime.getNil(); if (iVisited.isExclusive()) { if (!context.getCurrentScope().getValue(iVisited.getIndex(), iVisited.getDepth()).isTrue()) { result = evalInternal(context, iVisited.getBeginNode(), self).isTrue() ? runtime.getFalse() : runtime.getTrue(); context.getCurrentScope().setValue(iVisited.getIndex(), result, iVisited.getDepth()); return result; } else { if (evalInternal(context, iVisited.getEndNode(), self).isTrue()) { context.getCurrentScope().setValue(iVisited.getIndex(), runtime.getFalse(), iVisited.getDepth()); } return runtime.getTrue(); } } else { if (!context.getCurrentScope().getValue(iVisited.getIndex(), iVisited.getDepth()).isTrue()) { if (evalInternal(context, iVisited.getBeginNode(), self).isTrue()) { context.getCurrentScope().setValue( iVisited.getIndex(), evalInternal(context, iVisited.getEndNode(), self).isTrue() ? runtime.getFalse() : runtime.getTrue(), iVisited.getDepth()); return runtime.getTrue(); } else { return runtime.getFalse(); } } else { if (evalInternal(context, iVisited.getEndNode(), self).isTrue()) { context.getCurrentScope().setValue(iVisited.getIndex(), runtime.getFalse(), iVisited.getDepth()); } return runtime.getTrue(); } } } case NodeTypes.FLOATNODE: { FloatNode iVisited = (FloatNode) node; return RubyFloat.newFloat(runtime, iVisited.getValue()); } case NodeTypes.FORNODE: { ForNode iVisited = (ForNode) node; // For nodes do not have to create an addition scope so we just pass null context.preForLoopEval(Block.createBlock(iVisited.getVarNode(), null, iVisited.getCallable(), self)); try { while (true) { try { ISourcePosition position = context.getPosition(); context.beginCallArgs(); IRubyObject recv = null; try { recv = evalInternal(context, iVisited.getIterNode(), self); } finally { context.setPosition(position); context.endCallArgs(); } return recv.callMethod(context, "each", IRubyObject.NULL_ARRAY, CallType.NORMAL); } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.RETRY: // do nothing, allow loop to retry break; default: throw je; } } } } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.BREAK: IRubyObject breakValue = (IRubyObject) je.getPrimaryData(); return breakValue == null ? runtime.getNil() : breakValue; default: throw je; } } finally { context.postForLoopEval(); } } case NodeTypes.GLOBALASGNNODE: { GlobalAsgnNode iVisited = (GlobalAsgnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); runtime.getGlobalVariables().set(iVisited.getName(), result); return result; } case NodeTypes.GLOBALVARNODE: { GlobalVarNode iVisited = (GlobalVarNode) node; return runtime.getGlobalVariables().get(iVisited.getName()); } case NodeTypes.HASHNODE: { HashNode iVisited = (HashNode) node; Map hash = null; if (iVisited.getListNode() != null) { hash = new HashMap(iVisited.getListNode().size() / 2); for (Iterator iterator = iVisited.getListNode().iterator(); iterator.hasNext();) { // insert all nodes in sequence, hash them in the final instruction // KEY IRubyObject key = evalInternal(context, (Node) iterator.next(), self); IRubyObject value = evalInternal(context, (Node) iterator.next(), self); hash.put(key, value); } } if (hash == null) { return RubyHash.newHash(runtime); } return RubyHash.newHash(runtime, hash, runtime.getNil()); } case NodeTypes.IFNODE: { IfNode iVisited = (IfNode) node; IRubyObject result = evalInternal(context, iVisited.getCondition(), self); if (result.isTrue()) { node = iVisited.getThenBody(); continue bigloop; } else { node = iVisited.getElseBody(); continue bigloop; } } case NodeTypes.INSTASGNNODE: { InstAsgnNode iVisited = (InstAsgnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); self.setInstanceVariable(iVisited.getName(), result); return result; } case NodeTypes.INSTVARNODE: { InstVarNode iVisited = (InstVarNode) node; IRubyObject variable = self.getInstanceVariable(iVisited.getName()); return variable == null ? runtime.getNil() : variable; } // case NodeTypes.ISCOPINGNODE: // EvaluateVisitor.iScopingNodeVisitor.execute(this, node); // break; case NodeTypes.ITERNODE: { IterNode iVisited = (IterNode) node; context.preIterEval(Block.createBlock(iVisited.getVarNode(), new DynamicScope(iVisited.getScope(), context.getCurrentScope()), iVisited.getCallable(), self)); try { while (true) { try { context.setBlockAvailable(); return evalInternal(context, iVisited.getIterNode(), self); } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.RETRY: // allow loop to retry break; default: throw je; } } finally { context.clearBlockAvailable(); } } } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.BREAK: IRubyObject breakValue = (IRubyObject) je.getPrimaryData(); return breakValue == null ? runtime.getNil() : breakValue; default: throw je; } } finally { context.postIterEval(); } } case NodeTypes.LOCALASGNNODE: { LocalAsgnNode iVisited = (LocalAsgnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); // System.out.println("LSetting: " + iVisited.getName() + " at index " + iVisited.getIndex() + " and at depth " + iVisited.getDepth() + " and set " + result); context.getCurrentScope().setValue(iVisited.getIndex(), result, iVisited.getDepth()); return result; } case NodeTypes.LOCALVARNODE: { LocalVarNode iVisited = (LocalVarNode) node; //System.out.println("DGetting: " + iVisited.getName() + " at index " + iVisited.getIndex() + " and at depth " + iVisited.getDepth()); IRubyObject result = context.getCurrentScope().getValue(iVisited.getIndex(), iVisited.getDepth()); return result == null ? runtime.getNil() : result; } case NodeTypes.MATCH2NODE: { Match2Node iVisited = (Match2Node) node; IRubyObject recv = evalInternal(context, iVisited.getReceiverNode(), self); IRubyObject value = evalInternal(context, iVisited.getValueNode(), self); return ((RubyRegexp) recv).match(value); } case NodeTypes.MATCH3NODE: { Match3Node iVisited = (Match3Node) node; IRubyObject recv = evalInternal(context, iVisited.getReceiverNode(), self); IRubyObject value = evalInternal(context, iVisited.getValueNode(), self); if (value instanceof RubyString) { return ((RubyRegexp) recv).match(value); } else { return value.callMethod(context, "=~", recv); } } case NodeTypes.MATCHNODE: { MatchNode iVisited = (MatchNode) node; return ((RubyRegexp) evalInternal(context, iVisited.getRegexpNode(), self)).match2(); } case NodeTypes.MODULENODE: { ModuleNode iVisited = (ModuleNode) node; Node classNameNode = iVisited.getCPath(); String name = ((INameNode) classNameNode).getName(); RubyModule enclosingModule = getEnclosingModule(context, classNameNode, self); if (enclosingModule == null) { throw runtime.newTypeError("no outer class/module"); } RubyModule module; if (enclosingModule == runtime.getObject()) { module = runtime.getOrCreateModule(name); } else { module = enclosingModule.defineModuleUnder(name); } return evalClassDefinitionBody(context, iVisited.getScope(), iVisited.getBodyNode(), module, self); } case NodeTypes.MULTIPLEASGNNODE: { MultipleAsgnNode iVisited = (MultipleAsgnNode) node; return AssignmentVisitor.assign(context, self, iVisited, evalInternal(context, iVisited.getValueNode(), self), false); } case NodeTypes.NEWLINENODE: { NewlineNode iVisited = (NewlineNode) node; // something in here is used to build up ruby stack trace... context.setPosition(iVisited.getPosition()); if (isTrace(runtime)) { callTraceFunction(context, "line", self); } // TODO: do above but not below for additional newline nodes node = iVisited.getNextNode(); continue bigloop; } case NodeTypes.NEXTNODE: { NextNode iVisited = (NextNode) node; context.pollThreadEvents(); IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); // now used as an interpreter event JumpException je = new JumpException(JumpException.JumpType.NextJump); je.setPrimaryData(result); je.setSecondaryData(iVisited); //state.setCurrentException(je); throw je; } case NodeTypes.NILNODE: return runtime.getNil(); case NodeTypes.NOTNODE: { NotNode iVisited = (NotNode) node; IRubyObject result = evalInternal(context, iVisited.getConditionNode(), self); return result.isTrue() ? runtime.getFalse() : runtime.getTrue(); } case NodeTypes.NTHREFNODE: { NthRefNode iVisited = (NthRefNode) node; return RubyRegexp.nth_match(iVisited.getMatchNumber(), context.getBackref()); } case NodeTypes.OPASGNANDNODE: { BinaryOperatorNode iVisited = (BinaryOperatorNode) node; // add in reverse order IRubyObject result = evalInternal(context, iVisited.getFirstNode(), self); if (!result.isTrue()) return result; node = iVisited.getSecondNode(); continue bigloop; } case NodeTypes.OPASGNNODE: { OpAsgnNode iVisited = (OpAsgnNode) node; IRubyObject receiver = evalInternal(context, iVisited.getReceiverNode(), self); IRubyObject value = receiver.callMethod(context, iVisited.getVariableName()); if (iVisited.getOperatorName().equals("||")) { if (value.isTrue()) { return value; } value = evalInternal(context, iVisited.getValueNode(), self); } else if (iVisited.getOperatorName().equals("&&")) { if (!value.isTrue()) { return value; } value = evalInternal(context, iVisited.getValueNode(), self); } else { value = value.callMethod(context, iVisited.getOperatorName(), evalInternal(context, iVisited.getValueNode(), self)); } receiver.callMethod(context, iVisited.getVariableName() + "=", value); context.pollThreadEvents(); return value; } case NodeTypes.OPASGNORNODE: { OpAsgnOrNode iVisited = (OpAsgnOrNode) node; String def = getDefinition(context, iVisited.getFirstNode(), self); IRubyObject result = runtime.getNil(); if (def != null) { result = evalInternal(context, iVisited.getFirstNode(), self); } if (!result.isTrue()) { result = evalInternal(context, iVisited.getSecondNode(), self); } return result; } case NodeTypes.OPELEMENTASGNNODE: { OpElementAsgnNode iVisited = (OpElementAsgnNode) node; IRubyObject receiver = evalInternal(context, iVisited.getReceiverNode(), self); IRubyObject[] args = setupArgs(context, iVisited.getArgsNode(), self); IRubyObject firstValue = receiver.callMethod(context, "[]", args); if (iVisited.getOperatorName().equals("||")) { if (firstValue.isTrue()) { return firstValue; } firstValue = evalInternal(context, iVisited.getValueNode(), self); } else if (iVisited.getOperatorName().equals("&&")) { if (!firstValue.isTrue()) { return firstValue; } firstValue = evalInternal(context, iVisited.getValueNode(), self); } else { firstValue = firstValue.callMethod(context, iVisited.getOperatorName(), evalInternal(context, iVisited .getValueNode(), self)); } IRubyObject[] expandedArgs = new IRubyObject[args.length + 1]; System.arraycopy(args, 0, expandedArgs, 0, args.length); expandedArgs[expandedArgs.length - 1] = firstValue; return receiver.callMethod(context, "[]=", expandedArgs); } case NodeTypes.OPTNNODE: { OptNNode iVisited = (OptNNode) node; IRubyObject result = runtime.getNil(); while (RubyKernel.gets(runtime.getTopSelf(), IRubyObject.NULL_ARRAY).isTrue()) { loop: while (true) { // Used for the 'redo' command try { result = evalInternal(context, iVisited.getBodyNode(), self); break; } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.REDO: // do nothing, this iteration restarts break; case JumpType.NEXT: // recheck condition break loop; case JumpType.BREAK: // end loop return (IRubyObject) je.getPrimaryData(); default: throw je; } } } } return result; } case NodeTypes.ORNODE: { OrNode iVisited = (OrNode) node; IRubyObject result = evalInternal(context, iVisited.getFirstNode(), self); if (!result.isTrue()) { result = evalInternal(context, iVisited.getSecondNode(), self); } return result; } // case NodeTypes.POSTEXENODE: // EvaluateVisitor.postExeNodeVisitor.execute(this, node); // break; case NodeTypes.REDONODE: { context.pollThreadEvents(); // now used as an interpreter event JumpException je = new JumpException(JumpException.JumpType.RedoJump); je.setSecondaryData(node); throw je; } case NodeTypes.REGEXPNODE: { RegexpNode iVisited = (RegexpNode) node; String lang = null; int opts = iVisited.getOptions(); if((opts & 16) != 0) { // param n lang = "n"; } else if((opts & 48) != 0) { // param s lang = "s"; } else if((opts & 64) != 0) { // param s lang = "u"; } try { return RubyRegexp.newRegexp(runtime, iVisited.getPattern(), lang); } catch(java.util.regex.PatternSyntaxException e) { throw runtime.newSyntaxError(e.getMessage()); } } case NodeTypes.RESCUEBODYNODE: { RescueBodyNode iVisited = (RescueBodyNode) node; node = iVisited.getBodyNode(); continue bigloop; } case NodeTypes.RESCUENODE: { RescueNode iVisited = (RescueNode)node; RescuedBlock : while (true) { try { // Execute rescue block IRubyObject result = evalInternal(context, iVisited.getBodyNode(), self); // If no exception is thrown execute else block if (iVisited.getElseNode() != null) { if (iVisited.getRescueNode() == null) { runtime.getWarnings().warn(iVisited.getElseNode().getPosition(), "else without rescue is useless"); } result = evalInternal(context, iVisited.getElseNode(), self); } return result; } catch (RaiseException raiseJump) { RubyException raisedException = raiseJump.getException(); // TODO: Rubicon TestKernel dies without this line. A cursory glance implies we // falsely set $! to nil and this sets it back to something valid. This should // get fixed at the same time we address bug #1296484. runtime.getGlobalVariables().set("$!", raisedException); RescueBodyNode rescueNode = iVisited.getRescueNode(); while (rescueNode != null) { Node exceptionNodes = rescueNode.getExceptionNodes(); ListNode exceptionNodesList; if (exceptionNodes instanceof SplatNode) { exceptionNodesList = (ListNode) evalInternal(context, exceptionNodes, self); } else { exceptionNodesList = (ListNode) exceptionNodes; } if (isRescueHandled(context, raisedException, exceptionNodesList, self)) { try { return evalInternal(context, rescueNode, self); } catch (JumpException je) { if (je.getJumpType() == JumpException.JumpType.RetryJump) { // should be handled in the finally block below //state.runtime.getGlobalVariables().set("$!", state.runtime.getNil()); //state.threadContext.setRaisedException(null); continue RescuedBlock; } else { throw je; } } } rescueNode = rescueNode.getOptRescueNode(); } // no takers; bubble up throw raiseJump; } finally { // clear exception when handled or retried runtime.getGlobalVariables().set("$!", runtime.getNil()); } } } case NodeTypes.RETRYNODE: { context.pollThreadEvents(); JumpException je = new JumpException(JumpException.JumpType.RetryJump); throw je; } case NodeTypes.RETURNNODE: { ReturnNode iVisited = (ReturnNode) node; IRubyObject result = evalInternal(context, iVisited.getValueNode(), self); JumpException je = new JumpException(JumpException.JumpType.ReturnJump); je.setPrimaryData(iVisited.getTarget()); je.setSecondaryData(result); je.setTertiaryData(iVisited); throw je; } case NodeTypes.ROOTNODE: { RootNode iVisited = (RootNode) node; DynamicScope scope = iVisited.getScope(); // Serialization killed our dynamic scope. We can just create an empty one // since serialization cannot serialize an eval (which is the only thing // which is capable of having a non-empty dynamic scope). if (scope == null) { scope = new DynamicScope(iVisited.getStaticScope(), null); } // Each root node has a top-level scope that we need to push context.preRootNode(scope); // FIXME: Wire up BEGIN and END nodes try { return eval(context, iVisited.getBodyNode(), self); } finally { context.postRootNode(); } } case NodeTypes.SCLASSNODE: { SClassNode iVisited = (SClassNode) node; IRubyObject receiver = evalInternal(context, iVisited.getReceiverNode(), self); RubyClass singletonClass; if (receiver.isNil()) { singletonClass = runtime.getNilClass(); } else if (receiver == runtime.getTrue()) { singletonClass = runtime.getClass("TrueClass"); } else if (receiver == runtime.getFalse()) { singletonClass = runtime.getClass("FalseClass"); } else { if (runtime.getSafeLevel() >= 4 && !receiver.isTaint()) { throw runtime.newSecurityError("Insecure: can't extend object."); } singletonClass = receiver.getSingletonClass(); } if (context.getWrapper() != null) { singletonClass.extendObject(context.getWrapper()); singletonClass.includeModule(context.getWrapper()); } return evalClassDefinitionBody(context, iVisited.getScope(), iVisited.getBodyNode(), singletonClass, self); } case NodeTypes.SELFNODE: return self; case NodeTypes.SPLATNODE: { SplatNode iVisited = (SplatNode) node; return splatValue(evalInternal(context, iVisited.getValue(), self)); } //// case NodeTypes.STARNODE: //// EvaluateVisitor.starNodeVisitor.execute(this, node); //// break; case NodeTypes.STRNODE: { StrNode iVisited = (StrNode) node; return runtime.newString(iVisited.getValue()); } case NodeTypes.SUPERNODE: { SuperNode iVisited = (SuperNode) node; if (context.getFrameLastClass() == null) { String name = context.getFrameLastFunc(); throw runtime.newNameError("Superclass method '" + name + "' disabled.", name); } context.beginCallArgs(); IRubyObject[] args = null; try { args = setupArgs(context, iVisited.getArgsNode(), self); } finally { context.endCallArgs(); } return context.callSuper(args); } case NodeTypes.SVALUENODE: { SValueNode iVisited = (SValueNode) node; return aValueSplat(evalInternal(context, iVisited.getValue(), self)); } case NodeTypes.SYMBOLNODE: { SymbolNode iVisited = (SymbolNode) node; return runtime.newSymbol(iVisited.getName()); } case NodeTypes.TOARYNODE: { ToAryNode iVisited = (ToAryNode) node; return aryToAry(evalInternal(context, iVisited.getValue(), self)); } case NodeTypes.TRUENODE: { context.pollThreadEvents(); return runtime.getTrue(); } case NodeTypes.UNDEFNODE: { UndefNode iVisited = (UndefNode) node; if (context.getRubyClass() == null) { throw runtime .newTypeError("No class to undef method '" + iVisited.getName() + "'."); } context.getRubyClass().undef(iVisited.getName()); return runtime.getNil(); } case NodeTypes.UNTILNODE: { UntilNode iVisited = (UntilNode) node; IRubyObject result = runtime.getNil(); while (!(result = evalInternal(context, iVisited.getConditionNode(), self)).isTrue()) { loop: while (true) { // Used for the 'redo' command try { result = evalInternal(context, iVisited.getBodyNode(), self); break loop; } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.REDO: continue; case JumpType.NEXT: break loop; case JumpType.BREAK: return (IRubyObject) je.getPrimaryData(); default: throw je; } } } } return result; } case NodeTypes.VALIASNODE: { VAliasNode iVisited = (VAliasNode) node; runtime.getGlobalVariables().alias(iVisited.getNewName(), iVisited.getOldName()); return runtime.getNil(); } case NodeTypes.VCALLNODE: { VCallNode iVisited = (VCallNode) node; return self.callMethod(context, iVisited.getName(), IRubyObject.NULL_ARRAY, CallType.VARIABLE); } case NodeTypes.WHENNODE: assert false; return null; case NodeTypes.WHILENODE: { WhileNode iVisited = (WhileNode) node; IRubyObject result = runtime.getNil(); boolean firstTest = iVisited.evaluateAtStart(); while (!firstTest || (result = evalInternal(context, iVisited.getConditionNode(), self)).isTrue()) { firstTest = true; loop: while (true) { // Used for the 'redo' command try { evalInternal(context, iVisited.getBodyNode(), self); break loop; } catch (JumpException je) { switch (je.getJumpType().getTypeId()) { case JumpType.REDO: continue; case JumpType.NEXT: break loop; case JumpType.BREAK: return result; default: throw je; } } } } return result; } case NodeTypes.XSTRNODE: { XStrNode iVisited = (XStrNode) node; return self.callMethod(context, "`", runtime.newString(iVisited.getValue())); } case NodeTypes.YIELDNODE: { YieldNode iVisited = (YieldNode) node; IRubyObject result = evalInternal(context, iVisited.getArgsNode(), self); if (iVisited.getArgsNode() == null) { result = null; } return context.yieldCurrentBlock(result, null, null, iVisited.getCheckState()); } case NodeTypes.ZARRAYNODE: { return runtime.newArray(); } case NodeTypes.ZSUPERNODE: { if (context.getFrameLastClass() == null) { String name = context.getFrameLastFunc(); throw runtime.newNameError("superclass method '" + name + "' disabled", name); } return context.callSuper(context.getFrameArgs()); } } } while (true); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/62645b2160c482d6d16d79513df80eac48c28894/EvaluationState.java/buggy/src/org/jruby/evaluator/EvaluationState.java |
jj_la1[46] = jj_gen; | jj_la1[48] = jj_gen; | final public Object AExpression() throws ParseException { Object e, e2; Token op; e = Factor(); label_6: while (true) { if (jj_2_12(2)) { ; } else { break label_6; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[46] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_PLUS: op = jj_consume_token(OP_PLUS); break; case OP_MINUS: op = jj_consume_token(OP_MINUS); break; default: jj_la1[47] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[48] = jj_gen; ; } e2 = Factor(); if (op.kind == OP_PLUS) e = new Expression.AddBuilder(e, e2); else if (op.kind == OP_MINUS) e = new Expression.SubtractBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in AExpression()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[47] = jj_gen; | jj_la1[49] = jj_gen; | final public Object AExpression() throws ParseException { Object e, e2; Token op; e = Factor(); label_6: while (true) { if (jj_2_12(2)) { ; } else { break label_6; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[46] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_PLUS: op = jj_consume_token(OP_PLUS); break; case OP_MINUS: op = jj_consume_token(OP_MINUS); break; default: jj_la1[47] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[48] = jj_gen; ; } e2 = Factor(); if (op.kind == OP_PLUS) e = new Expression.AddBuilder(e, e2); else if (op.kind == OP_MINUS) e = new Expression.SubtractBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in AExpression()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[48] = jj_gen; | jj_la1[50] = jj_gen; | final public Object AExpression() throws ParseException { Object e, e2; Token op; e = Factor(); label_6: while (true) { if (jj_2_12(2)) { ; } else { break label_6; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[46] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_PLUS: op = jj_consume_token(OP_PLUS); break; case OP_MINUS: op = jj_consume_token(OP_MINUS); break; default: jj_la1[47] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[48] = jj_gen; ; } e2 = Factor(); if (op.kind == OP_PLUS) e = new Expression.AddBuilder(e, e2); else if (op.kind == OP_MINUS) e = new Expression.SubtractBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in AExpression()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[52] = jj_gen; | jj_la1[54] = jj_gen; | final public Object AndExpression() throws ParseException { Object e, e2; e = CExpression(); label_7: while (true) { if (jj_2_14(2)) { ; } else { break label_7; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[52] = jj_gen; ; } jj_consume_token(OP_AND); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[53] = jj_gen; ; } e2 = CExpression(); e = new Expression.AndBuilder(e, e2); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[53] = jj_gen; | jj_la1[55] = jj_gen; | final public Object AndExpression() throws ParseException { Object e, e2; e = CExpression(); label_7: while (true) { if (jj_2_14(2)) { ; } else { break label_7; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[52] = jj_gen; ; } jj_consume_token(OP_AND); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[53] = jj_gen; ; } e2 = CExpression(); e = new Expression.AndBuilder(e, e2); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[71] = jj_gen; | jj_la1[73] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[72] = jj_gen; | jj_la1[74] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[73] = jj_gen; | jj_la1[75] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[74] = jj_gen; | jj_la1[76] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[75] = jj_gen; | jj_la1[77] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[76] = jj_gen; | jj_la1[78] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[77] = jj_gen; | jj_la1[79] = jj_gen; | final public BlockBuilder Block(Subdirective[] subdirectives) throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; blockStack.push(subdirectives); if (jj_2_23(2147483647)) { jj_consume_token(LBRACE); EatWsNlIfNl(block); label_11: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[71] = jj_gen; break label_11; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[72] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[73] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); EatWsNlOrSpace(block); break; default: jj_la1[74] = jj_gen; ; } label_12: while (true) { if (jj_2_21(1)) { ; } else { break label_12; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: WMContentNoDirective(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[75] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[76] = jj_gen; if (jj_2_22(2147483647) && (lookahead_not_breaking_subd())) { Directive(block); } else { jj_consume_token(-1); throw new ParseException(); } } } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case END: jj_consume_token(END); block.eatOneWs(); break; default: jj_la1[77] = jj_gen; ; } } blockStack.pop(); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[50] = jj_gen; | jj_la1[52] = jj_gen; | final public Object CExpression() throws ParseException { // Note that CExpression is a little different from other binary // expression rules, as we don't want to accept a == b == c // Thanks to Aldona Majorek for pointing this out Object e1, e2=null; Token op=null; e1 = AExpression(); if (jj_2_13(2)) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[50] = jj_gen; ; } op = RelOp(); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[51] = jj_gen; ; } e2 = AExpression(); } else { ; } if (op == null) {if (true) return e1;} else switch (op.kind) { case OP_EQ: {if (true) return new Expression.CompareEqBuilder(e1, e2);} case OP_SET: {if (true) return new Expression.CompareEqBuilder(e1, e2);} case OP_NE: {if (true) return new Expression.CompareNeBuilder(e1, e2);} case OP_GT: {if (true) return new Expression.CompareGtBuilder(e1, e2);} case OP_GE: {if (true) return new Expression.CompareGeBuilder(e1, e2);} case OP_LE: {if (true) return new Expression.CompareLeBuilder(e1, e2);} case OP_LT: {if (true) return new Expression.CompareLtBuilder(e1, e2);} default: {if (true) throw new ParseException("internal parser error in CExpression()");} } throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[51] = jj_gen; | jj_la1[53] = jj_gen; | final public Object CExpression() throws ParseException { // Note that CExpression is a little different from other binary // expression rules, as we don't want to accept a == b == c // Thanks to Aldona Majorek for pointing this out Object e1, e2=null; Token op=null; e1 = AExpression(); if (jj_2_13(2)) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[50] = jj_gen; ; } op = RelOp(); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[51] = jj_gen; ; } e2 = AExpression(); } else { ; } if (op == null) {if (true) return e1;} else switch (op.kind) { case OP_EQ: {if (true) return new Expression.CompareEqBuilder(e1, e2);} case OP_SET: {if (true) return new Expression.CompareEqBuilder(e1, e2);} case OP_NE: {if (true) return new Expression.CompareNeBuilder(e1, e2);} case OP_GT: {if (true) return new Expression.CompareGtBuilder(e1, e2);} case OP_GE: {if (true) return new Expression.CompareGeBuilder(e1, e2);} case OP_LE: {if (true) return new Expression.CompareLeBuilder(e1, e2);} case OP_LT: {if (true) return new Expression.CompareLtBuilder(e1, e2);} default: {if (true) throw new ParseException("internal parser error in CExpression()");} } throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[57] = jj_gen; | jj_la1[59] = jj_gen; | final public void Comment(ParserBlockBuilder b) throws ParseException { jj_consume_token(POUNDPOUND); SetState(COMMENT); if (b.directiveOk()) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case RESTOFLINE: jj_consume_token(RESTOFLINE); break; default: jj_la1[57] = jj_gen; ; } b.eatTrailingWsNl(); } else { b.addElement("##"); } SetState(DEFAULT); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[56] = jj_gen; | jj_la1[58] = jj_gen; | final public void Directive(ParserBlockBuilder b) throws ParseException { Token t; Object o; Subdirective s; jj_consume_token(POUND); SetState(WM); if (jj_2_16(2147483647) && (b.directiveOk())) { t = jj_consume_token(WORD); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[56] = jj_gen; ; } o = parse_directive(t.image); b.eatTrailingWsNl(); b.addElement(o, t.beginLine, t.beginColumn); } else { b.addElement("#"); } SetState(DEFAULT); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[58] = jj_gen; | jj_la1[60] = jj_gen; | final public Object DollarReference() throws ParseException { int entryState = token_source.curLexState; Object o; SetState(WM); if (jj_2_17(2147483647)) { o = VariableReference(); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case DOLLAR: jj_consume_token(DOLLAR); o = "$"; break; default: jj_la1[58] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } SetState(entryState); {if (true) return o;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[43] = jj_gen; | jj_la1[45] = jj_gen; | final public Object Factor() throws ParseException { Object e, e2; Token op; e = Term(); label_5: while (true) { if (jj_2_11(2)) { ; } else { break label_5; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[43] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_MULT: op = jj_consume_token(OP_MULT); break; case OP_DIV: op = jj_consume_token(OP_DIV); break; default: jj_la1[44] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[45] = jj_gen; ; } e2 = Term(); if (op.kind == OP_MULT) e = new Expression.MultiplyBuilder(e, e2); else if (op.kind == OP_DIV) e = new Expression.DivideBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in Factor()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[44] = jj_gen; | jj_la1[46] = jj_gen; | final public Object Factor() throws ParseException { Object e, e2; Token op; e = Term(); label_5: while (true) { if (jj_2_11(2)) { ; } else { break label_5; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[43] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_MULT: op = jj_consume_token(OP_MULT); break; case OP_DIV: op = jj_consume_token(OP_DIV); break; default: jj_la1[44] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[45] = jj_gen; ; } e2 = Term(); if (op.kind == OP_MULT) e = new Expression.MultiplyBuilder(e, e2); else if (op.kind == OP_DIV) e = new Expression.DivideBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in Factor()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[45] = jj_gen; | jj_la1[47] = jj_gen; | final public Object Factor() throws ParseException { Object e, e2; Token op; e = Term(); label_5: while (true) { if (jj_2_11(2)) { ; } else { break label_5; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[43] = jj_gen; ; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_MULT: op = jj_consume_token(OP_MULT); break; case OP_DIV: op = jj_consume_token(OP_DIV); break; default: jj_la1[44] = jj_gen; jj_consume_token(-1); throw new ParseException(); } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[45] = jj_gen; ; } e2 = Term(); if (op.kind == OP_MULT) e = new Expression.MultiplyBuilder(e, e2); else if (op.kind == OP_DIV) e = new Expression.DivideBuilder(e, e2); else {if (true) throw new ParseException("internal parser error in Factor()");} } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[63] = jj_gen; | jj_la1[65] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[64] = jj_gen; | jj_la1[66] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[65] = jj_gen; | jj_la1[67] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[66] = jj_gen; | jj_la1[68] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[67] = jj_gen; | jj_la1[69] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[68] = jj_gen; | jj_la1[70] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[69] = jj_gen; | jj_la1[71] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[70] = jj_gen; | jj_la1[72] = jj_gen; | final public BlockBuilder LiteralBlock() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; if (jj_2_20(2147483647)) { jj_consume_token(LBRACE); label_9: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case END: case BEGIN: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[63] = jj_gen; break label_9; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case END: case BEGIN: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; default: jj_la1[64] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[65] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(RBRACE); } else { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: jj_consume_token(BEGIN); break; default: jj_la1[66] = jj_gen; ; } label_10: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[67] = jj_gen; break label_10; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: LiteralWMContent(block); break; case RBRACE: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[68] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[69] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(END); break; default: jj_la1[70] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[61] = jj_gen; | jj_la1[63] = jj_gen; | final public void LiteralWMContent(ParserBlockBuilder b) throws ParseException { Token t; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case QCHAR: t = jj_consume_token(QCHAR); b.addElement(t.image.substring(1)); break; case STUFF: case POUNDPOUND: case DOLLAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: t = jj_consume_token(STUFF); break; case SLASH: t = jj_consume_token(SLASH); break; case POUND: t = jj_consume_token(POUND); break; case DOLLAR: t = jj_consume_token(DOLLAR); break; case POUNDPOUND: t = jj_consume_token(POUNDPOUND); break; default: jj_la1[61] = jj_gen; jj_consume_token(-1); throw new ParseException(); } b.addElement(t.image); break; default: jj_la1[62] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[62] = jj_gen; | jj_la1[64] = jj_gen; | final public void LiteralWMContent(ParserBlockBuilder b) throws ParseException { Token t; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case QCHAR: t = jj_consume_token(QCHAR); b.addElement(t.image.substring(1)); break; case STUFF: case POUNDPOUND: case DOLLAR: case SLASH: case POUND: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: t = jj_consume_token(STUFF); break; case SLASH: t = jj_consume_token(SLASH); break; case POUND: t = jj_consume_token(POUND); break; case DOLLAR: t = jj_consume_token(DOLLAR); break; case POUNDPOUND: t = jj_consume_token(POUNDPOUND); break; default: jj_la1[61] = jj_gen; jj_consume_token(-1); throw new ParseException(); } b.addElement(t.image); break; default: jj_la1[62] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[54] = jj_gen; | jj_la1[56] = jj_gen; | final public Object OrExpression() throws ParseException { Object e, e2; e = AndExpression(); label_8: while (true) { if (jj_2_15(2)) { ; } else { break label_8; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[54] = jj_gen; ; } jj_consume_token(OP_OR); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[55] = jj_gen; ; } e2 = AndExpression(); e = new Expression.OrBuilder(e, e2); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[55] = jj_gen; | jj_la1[57] = jj_gen; | final public Object OrExpression() throws ParseException { Object e, e2; e = AndExpression(); label_8: while (true) { if (jj_2_15(2)) { ; } else { break label_8; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[54] = jj_gen; ; } jj_consume_token(OP_OR); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[55] = jj_gen; ; } e2 = AndExpression(); e = new Expression.OrBuilder(e, e2); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[49] = jj_gen; | jj_la1[51] = jj_gen; | final public Token RelOp() throws ParseException { Token t; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case OP_EQ: t = jj_consume_token(OP_EQ); break; case OP_SET: t = jj_consume_token(OP_SET); break; case OP_NE: t = jj_consume_token(OP_NE); break; case OP_GT: t = jj_consume_token(OP_GT); break; case OP_GE: t = jj_consume_token(OP_GE); break; case OP_LE: t = jj_consume_token(OP_LE); break; case OP_LT: t = jj_consume_token(OP_LT); break; default: jj_la1[49] = jj_gen; jj_consume_token(-1); throw new ParseException(); } {if (true) return t;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[41] = jj_gen; | jj_la1[43] = jj_gen; | final public Object Term() throws ParseException { Object e; Token t; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case DOLLAR: e = VariableReference(); break; case LPAREN: jj_consume_token(LPAREN); e = Expression(); jj_consume_token(RPAREN); break; case QUOTE: case SQUOTE: e = QuotedString(); break; case LBRACKET: e = BracketList(); break; case NULL: jj_consume_token(NULL); e = null; break; case TRUE: jj_consume_token(TRUE); e = Boolean.TRUE; break; case FALSE: jj_consume_token(FALSE); e = Boolean.FALSE; break; case OP_NOT: jj_consume_token(OP_NOT); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[41] = jj_gen; ; } e = Term(); e = new Expression.NotBuilder(e); break; case NUMBER: t = jj_consume_token(NUMBER); try { e = new Integer(t.image); } catch (NumberFormatException ex) { e=null; } break; case OP_MINUS: jj_consume_token(OP_MINUS); t = jj_consume_token(NUMBER); try { int i = Integer.parseInt(t.image); e = new Integer(-i); } catch (NumberFormatException ex) { e=null; } break; default: jj_la1[42] = jj_gen; jj_consume_token(-1); throw new ParseException(); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[42] = jj_gen; | jj_la1[44] = jj_gen; | final public Object Term() throws ParseException { Object e; Token t; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case DOLLAR: e = VariableReference(); break; case LPAREN: jj_consume_token(LPAREN); e = Expression(); jj_consume_token(RPAREN); break; case QUOTE: case SQUOTE: e = QuotedString(); break; case LBRACKET: e = BracketList(); break; case NULL: jj_consume_token(NULL); e = null; break; case TRUE: jj_consume_token(TRUE); e = Boolean.TRUE; break; case FALSE: jj_consume_token(FALSE); e = Boolean.FALSE; break; case OP_NOT: jj_consume_token(OP_NOT); switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case WS: jj_consume_token(WS); break; default: jj_la1[41] = jj_gen; ; } e = Term(); e = new Expression.NotBuilder(e); break; case NUMBER: t = jj_consume_token(NUMBER); try { e = new Integer(t.image); } catch (NumberFormatException ex) { e=null; } break; case OP_MINUS: jj_consume_token(OP_MINUS); t = jj_consume_token(NUMBER); try { int i = Integer.parseInt(t.image); e = new Integer(-i); } catch (NumberFormatException ex) { e=null; } break; default: jj_la1[42] = jj_gen; jj_consume_token(-1); throw new ParseException(); } {if (true) return e;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[59] = jj_gen; | jj_la1[61] = jj_gen; | final public void WMContent(ParserBlockBuilder b) throws ParseException { Token t; Object o, dr; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: t = jj_consume_token(STUFF); b.addElement(t.image); break; case QCHAR: t = jj_consume_token(QCHAR); b.addElement(t.image.substring(1)); b.markLiteral(); break; case SLASH: t = jj_consume_token(SLASH); b.addElement(t.image); break; case POUND: Directive(b); break; case POUNDPOUND: Comment(b); break; default: jj_la1[59] = jj_gen; if (jj_2_18(2147483647)) { t=getToken(1); dr = DollarReference(); b.addElement(dr, t.beginLine, t.beginColumn); } else { jj_consume_token(-1); throw new ParseException(); } } } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[60] = jj_gen; | jj_la1[62] = jj_gen; | final public void WMContentNoDirective(ParserBlockBuilder b) throws ParseException { Token t; Object o, dr; switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: t = jj_consume_token(STUFF); b.addElement(t.image); break; case QCHAR: t = jj_consume_token(QCHAR); b.addElement(t.image.substring(1)); b.markLiteral(); break; case SLASH: t = jj_consume_token(SLASH); b.addElement(t.image); break; case POUNDPOUND: Comment(b); break; default: jj_la1[60] = jj_gen; if (jj_2_19(2147483647)) { t=getToken(1); dr = DollarReference(); b.addElement(dr, t.beginLine, t.beginColumn); } else { jj_consume_token(-1); throw new ParseException(); } } } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[78] = jj_gen; | jj_la1[80] = jj_gen; | final public BlockBuilder WMDocument() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; label_13: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[78] = jj_gen; break label_13; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case RBRACE: case END: case BEGIN: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[79] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[80] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(0); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[79] = jj_gen; | jj_la1[81] = jj_gen; | final public BlockBuilder WMDocument() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; label_13: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[78] = jj_gen; break label_13; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case RBRACE: case END: case BEGIN: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[79] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[80] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(0); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
jj_la1[80] = jj_gen; | jj_la1[82] = jj_gen; | final public BlockBuilder WMDocument() throws ParseException { ParserBlockBuilder block = new ParserBlockBuilder(templateName); Token t; label_13: while (true) { switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case RBRACE: case END: case BEGIN: case LBRACE: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: ; break; default: jj_la1[78] = jj_gen; break label_13; } switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case STUFF: case POUNDPOUND: case DOLLAR: case QCHAR: case SLASH: case POUND: WMContent(block); break; case RBRACE: case END: case BEGIN: case LBRACE: switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { case BEGIN: t = jj_consume_token(BEGIN); break; case END: t = jj_consume_token(END); break; case LBRACE: t = jj_consume_token(LBRACE); break; case RBRACE: t = jj_consume_token(RBRACE); break; default: jj_la1[79] = jj_gen; jj_consume_token(-1); throw new ParseException(); } block.addElement(t.image); break; default: jj_la1[80] = jj_gen; jj_consume_token(-1); throw new ParseException(); } } jj_consume_token(0); {if (true) return block;} throw new Error("Missing return statement in function"); } | 52513 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52513/126c8b01768c9be523a6baffb01538d1aba40e1e/WMParser_impl.java/buggy/webmacro/src/org/webmacro/parser/WMParser_impl.java |
"WEB-INF/services.xml", "WEB-INF/dao.xml", "WEB-INF/data.xml", "WEB-INF/test/config-test.xml", "WEB-INF/test/test.xml"}; | "WEB-INF/jms.xml" }; | protected String[] getConfigLocations() { return new String[] { "WEB-INF/services.xml", "WEB-INF/dao.xml", "WEB-INF/data.xml", "WEB-INF/test/config-test.xml", "WEB-INF/test/test.xml"}; } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/c69d196330f830906f9e7a7ada7e29b8d88daa2d/LeftOuterJoinTest.java/clean/components/server/test/org/openmicroscopy/omero/server/itests/LeftOuterJoinTest.java |
hb = (HierarchyBrowsing) applicationContext.getBean("hierarchyBrowsingService"); | protected void onSetUp() throws Exception { hb = (HierarchyBrowsing) applicationContext.getBean("hierarchyBrowsingService"); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/c69d196330f830906f9e7a7ada7e29b8d88daa2d/LeftOuterJoinTest.java/clean/components/server/test/org/openmicroscopy/omero/server/itests/LeftOuterJoinTest.java |
|
assertTrue("Need two pixInfos, please.",p.collectFromPlaneInfo(null).size() == 2); for (PlaneInfo pi : (List<PlaneInfo>)p.collectFromPlaneInfo(null)) | assertTrue("Need two pixInfos, please.",p.collectPlaneInfo(null).size() == 2); for (PlaneInfo pi : (List<PlaneInfo>)p.collectPlaneInfo(null)) | public void testNewCollectionFieldOnDetachedPixels() throws Exception { // PREPARE ------------------------------------------------- PlaneInfo pi1 = new PlaneInfo(),pi2 = new PlaneInfo(); pi1.setPixels(p); pi1.setExposureTime(new Float(10)); pi1.setTimestamp(new Float(-11)); pi2.setPixels(p); pi2.setExposureTime(new Float(100)); pi2.setTimestamp(new Float(-193)); p.addToPlaneInfo( pi1 ); p.addToPlaneInfo( pi2 ); p = (Pixels) iUpdate.saveAndReturnObject(p); flush(); clear(); // TEST ---------------------------------------------------- assertTrue("Need two pixInfos, please.",p.collectFromPlaneInfo(null).size() == 2); for (PlaneInfo pi : (List<PlaneInfo>)p.collectFromPlaneInfo(null)) { assertTrue("Need an id, please.", pi.getId().longValue()>0); } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/7b5c704279f82fa929138305f70f2f5e6b462c69/DetachedPixelsGraphTest.java/clean/components/server/test/ome/server/itests/update/DetachedPixelsGraphTest.java |
{ AnnotatorModel model = new AnnotatorModel(objects); AnnotatorComponent component = new AnnotatorComponent(model); model.initialize(component); component.initialize(); return component; } | { AnnotatorModel model = new AnnotatorModel(objects); AnnotatorComponent component = new AnnotatorComponent(model); model.initialize(component); component.initialize(); return component; } | private Annotator createAnnotator(Set objects) { AnnotatorModel model = new AnnotatorModel(objects); AnnotatorComponent component = new AnnotatorComponent(model); model.initialize(component); component.initialize(); return component; } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/464efde90db6bc5095c0a7e5952f51ad0f37ca86/AnnotatorFactory.java/buggy/SRC/org/openmicroscopy/shoola/agents/util/annotator/view/AnnotatorFactory.java |
JavaClass javaClass = javaSources[i].getClasses()[0]; ElementMapping element = loadElement(javaClass); if (element != null && !javaClass.isAbstract()) { elements.add(element); } else { log.debug("No XML annotation found for type: " + javaClass.getFullyQualifiedName()); } | if( javaSources[i].getClasses().length == 0 ) { log.warn("No Java Classes defined in: " + javaSources[i].getURL() ); } else { JavaClass[] classes = javaSources[i].getClasses(); for (int j = 0; j < classes.length; j++) { JavaClass javaClass = classes[j]; ElementMapping element = loadElement(javaClass); if (element != null && !javaClass.isAbstract()) { elements.add(element); } else { log.debug("No XML annotation found for type: " + javaClass.getFullyQualifiedName()); } } } | private List loadElements(JavaDocBuilder builder) { JavaSource[] javaSources = builder.getSources(); List elements = new ArrayList(); for (int i = 0; i < javaSources.length; i++) { JavaClass javaClass = javaSources[i].getClasses()[0]; ElementMapping element = loadElement(javaClass); if (element != null && !javaClass.isAbstract()) { elements.add(element); } else { log.debug("No XML annotation found for type: " + javaClass.getFullyQualifiedName()); } } return elements; } | 52533 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52533/a01ace06a3dd32d06814b0e4764a498ee1be700c/QdoxMappingLoader.java/clean/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java |
{ view.addMouseListener(this); view.addMouseMotionListener(this); } | { view.addMouseListener(this); view.addMouseMotionListener(this); } | private void attachListeners() { view.addMouseListener(this); view.addMouseMotionListener(this); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ Point p = e.getPoint(); if (dragging) { if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputStartKnob = true; inputStartKnob = false; inputEndKnob = false; outputEndKnob = false; setOutputWindowStart(p.y); } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputEndKnob = true; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; setOutputWindowEnd(p.y); } } } | { Point p = e.getPoint(); if (dragging) { if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputStartKnob = true; inputStartKnob = false; inputEndKnob = false; outputEndKnob = false; setOutputWindowStart(p.y); } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputEndKnob = true; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; setOutputWindowEnd(p.y); } } } | public void mouseDragged(MouseEvent e) { Point p = e.getPoint(); if (dragging) { if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputStartKnob = true; inputStartKnob = false; inputEndKnob = false; outputEndKnob = false; setOutputWindowStart(p.y); } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { curRealValue = convertGraphicsIntoReal(p.y-topBorder); outputEndKnob = true; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; setOutputWindowEnd(p.y); } } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ Point p = e.getPoint(); if (!dragging) { dragging = true; if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); int v = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; curRealValue = v; } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { outputStartKnob = true; inputEndKnob = false; inputStartKnob = false; outputEndKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowStart(p.y); } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { outputEndKnob = true; inputEndKnob = false; inputStartKnob = false; outputStartKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowEnd(p.y); } } } | { Point p = e.getPoint(); if (!dragging) { dragging = true; if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); int v = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; curRealValue = v; } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { outputStartKnob = true; inputEndKnob = false; inputStartKnob = false; outputEndKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowStart(p.y); } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { outputEndKnob = true; inputEndKnob = false; inputStartKnob = false; outputStartKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowEnd(p.y); } } } | public void mousePressed(MouseEvent e) { Point p = e.getPoint(); if (!dragging) { dragging = true; if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && p.x <= maxEndX && p.x >= absMin && type == QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); int v = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; curRealValue = v; //control.setInputWindowEnd(v); } if (boxEnd.contains(p) && p.x >= leftBorder && p.x <= lS && p.x >= maxStartX && type != QuantumFactory.EXPONENTIAL) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputEndKnob = true; inputStartKnob = false; outputEndKnob = false; outputStartKnob = false; //synchronize the view. control.setInputWindowEnd(curRealValue); } if (boxStart.contains(p) && p.x >= leftBorder && p.x <= lS && p.x <= minEndX) { int min = control.getGlobalMinimum(); curRealValue = convertGraphicsIntoReal(p.x-leftBorder, control.getGlobalMaximum()-min, view.getInputGraphicsRange(), min); inputStartKnob = true; inputEndKnob = false; outputEndKnob = false; outputStartKnob = false; //synchronize the view. control.setInputWindowStart(curRealValue); } if (boxOutputStart.contains(p) && p.y >= minEndOutputY && p.y <= tS) { outputStartKnob = true; inputEndKnob = false; inputStartKnob = false; outputEndKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowStart(p.y); //update the view. } if (boxOutputEnd.contains(p) && p.y <= maxStartOutputY && p.y >= topBorder) { outputEndKnob = true; inputEndKnob = false; inputStartKnob = false; outputStartKnob = false; curRealValue = convertGraphicsIntoReal(p.y-topBorder); setOutputWindowEnd(p.y); //update the view. } } //else dragging already in progress } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ if (inputStartKnob) control.setChannelWindowStart(curRealValue); else if (inputEndKnob) control.setChannelWindowEnd(curRealValue); else if (outputStartKnob) control.setCodomainLowerBound(curRealValue); else if (outputEndKnob) control.setCodomainUpperBound(curRealValue); dragging = false; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; outputEndKnob = false; } | { if (inputStartKnob) control.setChannelWindowStart(curRealValue); else if (inputEndKnob) control.setChannelWindowEnd(curRealValue); else if (outputStartKnob) control.setCodomainLowerBound(curRealValue); else if (outputEndKnob) control.setCodomainUpperBound(curRealValue); dragging = false; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; outputEndKnob = false; } | public void mouseReleased(MouseEvent e) { if (inputStartKnob) control.setChannelWindowStart(curRealValue); else if (inputEndKnob) control.setChannelWindowEnd(curRealValue); else if (outputStartKnob) control.setCodomainLowerBound(curRealValue); else if (outputEndKnob) control.setCodomainUpperBound(curRealValue); dragging = false; inputStartKnob = false; inputEndKnob = false; outputStartKnob = false; outputEndKnob = false; } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ maxStartX = x+extraControl; boxStart.setBounds(x-triangleW, tS+triangleW+1, 4*length, bottomBorder+bottomBorderSupp); } | { maxStartX = x+extraControl; boxStart.setBounds(x-triangleW, tS+triangleW+1, 4*length, bottomBorder+bottomBorderSupp); } | void setInputStartBox(int x) { //maxStartX = x+2*triangleW; maxStartX = x+extraControl; boxStart.setBounds(x-triangleW, tS+triangleW+1, 4*length, bottomBorder+bottomBorderSupp); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ | { | private void setOutputEndBox(int y) { //minEndOutputY = y+triangleW; minEndOutputY = y+extraControl; boxOutputEnd.setBounds(lS, y-triangleW, leftBorder, 4*length); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
boxOutputEnd.setBounds(lS, y-triangleW, leftBorder, 4*length); } | boxOutputEnd.setBounds(lS, y-triangleW, leftBorder, 4*length); } | private void setOutputEndBox(int y) { //minEndOutputY = y+triangleW; minEndOutputY = y+extraControl; boxOutputEnd.setBounds(lS, y-triangleW, leftBorder, 4*length); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ | { | private void setOutputStartBox(int y) { //maxStartOutputY = y-2*triangleW; maxStartOutputY = y-extraControl; boxOutputStart.setBounds(0, y-2*triangleW, leftBorder, 4*length); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
boxOutputStart.setBounds(0, y-2*triangleW, leftBorder, 4*length); } | boxOutputStart.setBounds(0, y-2*triangleW, leftBorder, 4*length); } | private void setOutputStartBox(int y) { //maxStartOutputY = y-2*triangleW; maxStartOutputY = y-extraControl; boxOutputStart.setBounds(0, y-2*triangleW, leftBorder, 4*length); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ setOutputEndBox(y); view.updateOutputEnd(y); } | { setOutputEndBox(y); view.updateOutputEnd(y); } | void setOutputWindowEnd(int y) { setOutputEndBox(y); view.updateOutputEnd(y); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
{ setOutputStartBox(y); view.updateOutputStart(y); } | { setOutputStartBox(y); view.updateOutputStart(y); } | void setOutputWindowStart(int y) { setOutputStartBox(y); view.updateOutputStart(y); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/1722ebf9ac60fc8e45cdc8d0049e85db5b86715c/GraphicsRepresentationManager.java/buggy/SRC/org/openmicroscopy/shoola/agents/rnd/pane/GraphicsRepresentationManager.java |
int N = Integer.parseInt(args[0]) - 1; | public static void main(String args[]) { //@START int N = Integer.parseInt(args[0]) - 1; NumberFormat nf = NumberFormat.getInstance(); nf.setMaximumFractionDigits(9); nf.setMinimumFractionDigits(9); nf.setGroupingUsed(false); while (N-- > 0) { gen_random(100); } System.out.println(nf.format(gen_random(100))); //@END } | 53330 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53330/eb6c850277407b38bcaefb81155941da0f27b849/random.java/buggy/tests/shootout/java-start/random.java |
|
testArgsCount(recv.getRuntime(), args); | arity.checkArity(recv.getRuntime(), args); | public IRubyObject execute(IRubyObject recv, IRubyObject[] args) { args = (args != null) ? args : IRubyObject.NULL_ARRAY; testArgsCount(recv.getRuntime(), args); return invokeMethod(recv, args); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/765ab8f2eeed4e7c0c131b35b7ecadb0ee2855fd/AbstractCallback.java/clean/src/org/jruby/runtime/callback/AbstractCallback.java |
throw new RuntimeException( "Cannot call \"" + methodName + "\" in class \"" + type.getName() + "\". " + getExpectedArgsString((IRubyObject[]) originalArgs)); | assert false : e; return null; | protected final Object[] packageRestArgumentsForReflection(final Object[] originalArgs) { IRubyObject[] restArray = new IRubyObject[originalArgs.length - (argumentTypes.length - 1)]; Object[] result = new Object[argumentTypes.length]; try { System.arraycopy(originalArgs, argumentTypes.length - 1, restArray, 0, originalArgs.length - (argumentTypes.length - 1)); } catch (ArrayIndexOutOfBoundsException e) { throw new RuntimeException( "Cannot call \"" + methodName + "\" in class \"" + type.getName() + "\". " + getExpectedArgsString((IRubyObject[]) originalArgs)); } System.arraycopy(originalArgs, 0, result, 0, argumentTypes.length - 1); result[argumentTypes.length - 1] = restArray; return result; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/765ab8f2eeed4e7c0c131b35b7ecadb0ee2855fd/AbstractCallback.java/clean/src/org/jruby/runtime/callback/AbstractCallback.java |
className = className.replace("/", "."); | className = className.replace('/', '.'); | private static boolean isExcluded(String sourceName, String[] excludedClasses) { if (excludedClasses == null) { return false; } String className = sourceName; if (sourceName.endsWith(".java")) { className = className.substring(0, className.length() - ".java".length()); } className = className.replace("/", "."); for (int i = 0; i < excludedClasses.length; i++) { String excludedClass = excludedClasses[i]; if (className.equals(excludedClass)) { return true; } } return false; } | 52533 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52533/8bd98627f738e930150b474899895f43381d8a42/QdoxMappingLoader.java/clean/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java |
zoomParamListeners = new HashSet(); | private void init(BrowserTopModel topModel) { env = BrowserEnvironment.getInstance(); setBackground(new Color(192,192,192)); backgroundNode = new BackgroundNode(); getLayer().addChild(backgroundNode); layoutMap = new HashMap(); footprint = new Rectangle2D.Double(0,0,0,0); hoverSensitive = new HashSet(); regionSensitive = new HashSet(); removeInputEventListener(getZoomEventHandler()); removeInputEventListener(getPanEventHandler()); // default panning mode (may replace this, but probably not) overlayCamera = new BrowserCamera(topModel,getCamera()); hoverSensitive.add(overlayCamera); regionSensitive.add(overlayCamera); scaleToShow = true; addMouseListener(new MouseAdapter() { public void mouseEntered(MouseEvent me) { for(Iterator iter = hoverSensitive.iterator(); iter.hasNext();) { HoverSensitive hover = (HoverSensitive)iter.next(); hover.contextEntered(); } } public void mouseExited(MouseEvent me) { for(Iterator iter = hoverSensitive.iterator(); iter.hasNext();) { HoverSensitive hover = (HoverSensitive)iter.next(); hover.contextExited(); } } }); // OK, now, dispatch to the underlying nodes addInputEventListener(BrowserViewEventDispatcher.getDefaultMouseHandler()); addInputEventListener(BrowserViewEventDispatcher.getDefaultDragHandler()); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
|
setZoomToScale(); | setZoomToScale(true); | public void modeChanged(String className, BrowserMode mode) { // boooooo. if(className == null) { return; } else if(className.equals(BrowserModel.PAN_MODE_NAME)) { if(mode == BrowserMode.HAND_MODE) { // TODO: change drag listener here } else if(mode == BrowserMode.NO_HAND_MODE) { // TODO: change back. } } else if(className.equals(BrowserModel.MAJOR_UI_MODE_NAME)) { if(mode == BrowserMode.DEFAULT_MODE) { // TODO: fill this in } } else if(className.equals(BrowserModel.SELECT_MODE_NAME)) { if(mode == BrowserMode.SELECTING_MODE) { selectionInProgress = true; repaint(); } else { selectionInProgress = false; repaint(); } } else if(className.equals(BrowserModel.ZOOM_MODE_NAME)) { if(mode == BrowserMode.ZOOM_TO_FIT_MODE) { setZoomToScale(); } else if(mode == BrowserMode.ZOOM_ACTUAL_MODE) { setZoomLevel(1); } else if(mode == BrowserMode.ZOOM_50_MODE) { setZoomLevel(0.5); } else if(mode == BrowserMode.ZOOM_75_MODE) { setZoomLevel(0.75); } else if(mode == BrowserMode.ZOOM_200_MODE) { setZoomLevel(2); } } else if(className.equals(BrowserModel.SEMANTIC_MODE_NAME)) { if(mode == BrowserMode.IMAGE_NAME_MODE) { semanticHoverThumbnailAction = PiccoloActionFactory.getImageNameEnterAction(semanticLayer); defaultTOverActions.setMouseEnterAction(PiccoloModifiers.NORMAL, semanticHoverThumbnailAction); setThumbnailOverActions(defaultTOverActions); } else if(mode == BrowserMode.SEMANTIC_ZOOMING_MODE) { semanticHoverThumbnailAction = PiccoloActionFactory.getSemanticEnterAction(semanticLayer); defaultTOverActions.setMouseEnterAction(PiccoloModifiers.NORMAL, semanticHoverThumbnailAction); setThumbnailOverActions(defaultTOverActions); } } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
setZoomToScale(false); | public void modeChanged(String className, BrowserMode mode) { // boooooo. if(className == null) { return; } else if(className.equals(BrowserModel.PAN_MODE_NAME)) { if(mode == BrowserMode.HAND_MODE) { // TODO: change drag listener here } else if(mode == BrowserMode.NO_HAND_MODE) { // TODO: change back. } } else if(className.equals(BrowserModel.MAJOR_UI_MODE_NAME)) { if(mode == BrowserMode.DEFAULT_MODE) { // TODO: fill this in } } else if(className.equals(BrowserModel.SELECT_MODE_NAME)) { if(mode == BrowserMode.SELECTING_MODE) { selectionInProgress = true; repaint(); } else { selectionInProgress = false; repaint(); } } else if(className.equals(BrowserModel.ZOOM_MODE_NAME)) { if(mode == BrowserMode.ZOOM_TO_FIT_MODE) { setZoomToScale(); } else if(mode == BrowserMode.ZOOM_ACTUAL_MODE) { setZoomLevel(1); } else if(mode == BrowserMode.ZOOM_50_MODE) { setZoomLevel(0.5); } else if(mode == BrowserMode.ZOOM_75_MODE) { setZoomLevel(0.75); } else if(mode == BrowserMode.ZOOM_200_MODE) { setZoomLevel(2); } } else if(className.equals(BrowserModel.SEMANTIC_MODE_NAME)) { if(mode == BrowserMode.IMAGE_NAME_MODE) { semanticHoverThumbnailAction = PiccoloActionFactory.getImageNameEnterAction(semanticLayer); defaultTOverActions.setMouseEnterAction(PiccoloModifiers.NORMAL, semanticHoverThumbnailAction); setThumbnailOverActions(defaultTOverActions); } else if(mode == BrowserMode.SEMANTIC_ZOOMING_MODE) { semanticHoverThumbnailAction = PiccoloActionFactory.getSemanticEnterAction(semanticLayer); defaultTOverActions.setMouseEnterAction(PiccoloModifiers.NORMAL, semanticHoverThumbnailAction); setThumbnailOverActions(defaultTOverActions); } } } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
|
scaleToShow = false; | if(scaleToShow) return; | public void setZoomLevel(double zoomLevel) { // error condition if(zoomLevel <= 0) { return; } scaleToShow = false; Dimension dim = getSize(); double width = dim.getWidth(); double height = dim.getHeight(); double scale = getCamera().getViewScale(); double viewWidth = getCamera().getViewBounds().getWidth(); double viewHeight = getCamera().getViewBounds().getHeight(); double viewCenterX = getCamera().getViewBounds().getCenterX(); double viewCenterY = getCamera().getViewBounds().getCenterY(); double scaleX = 0; double scaleY = 0; System.err.println(footprint.getWidth()+","+footprint.getWidth()); System.err.println("dim:"+width+","+height); if(width/zoomLevel < footprint.getWidth()) { scaleX = viewCenterX; if((viewCenterX - (scale/zoomLevel)*viewWidth/2) < 0) { scaleX = 0; } } if(height/zoomLevel < footprint.getHeight()) { scaleY = viewCenterY; if((viewCenterY - (scale/zoomLevel)*viewWidth/2) < 0) { scaleY = 0; } } System.err.println("scaleX="+scaleX+", scaleY="+scaleY); getCamera().scaleViewAboutPoint(zoomLevel/scale,scaleX,scaleY); updateConstraints(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
public void setZoomToScale() | public void setZoomToScale(boolean zoomToScale) | public void setZoomToScale() { scaleToShow = true; updateConstraints(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
scaleToShow = true; updateConstraints(); | if(scaleToShow != zoomToScale) { scaleToShow = zoomToScale; updateConstraints(); } | public void setZoomToScale() { scaleToShow = true; updateConstraints(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
for(Iterator iter = zoomParamListeners.iterator(); iter.hasNext();) { ZoomParamListener listener = (ZoomParamListener)iter.next(); listener.zoomLevelChanged(viewScale); } | public void updateConstraints() { Dimension dimension = getSize(); double width = dimension.getWidth(); double height = dimension.getHeight(); double xRatio = width / footprint.getWidth(); double yRatio = height / footprint.getHeight(); // for some reason, setting setViewScale(0) screws things up // in a big way. if(scaleToShow) { if((xRatio < 1 || yRatio < 1) && (xRatio != 0 && yRatio != 0)) { double min = Math.min(xRatio,yRatio); getCamera().setViewScale(min); } else { getCamera().setViewScale(1); } } boundCameraPosition(); double viewScale = getCamera().getViewScale(); backgroundNode.setBounds(0,0,width/viewScale,height/viewScale); // update things for(Iterator iter = regionSensitive.iterator(); iter.hasNext();) { RegionSensitive rs = (RegionSensitive)iter.next(); rs.setActiveRegion(footprint); } System.err.println(footprint); System.err.println("Dim: "+width+","+height); overlayCamera.cameraResized(new Rectangle2D.Double(0,0,width,height)); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/931190c640a4d36141bc5769628dc3f10cf66641/BrowserView.java/clean/SRC/org/openmicroscopy/shoola/agents/browser/ui/BrowserView.java |
|
if (ChainBuilderAgent.DEBUG) { long end = System.currentTimeMillis()-start; System.err.println("time for building chain palette "+chainBuilt); System.err.println("time for building chain palette + overview" +end); } | public void contentComplete() { chainWindow.buildGUI(); overview.buildGUI(); } | 54698 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54698/a806bf744289bb0eed666b235887c8680d549d94/UIManager.java/clean/SRC/org/openmicroscopy/shoola/agents/chainbuilder/ui/UIManager.java |
|
public RubyObject id() { | public RubyFixnum id() { | public RubyObject id() { return RubyFixnum.newFixnum(getRuby(), System.identityHashCode(this)); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0d05f52f4b20deb7938755dd220bb81c2c2b208e/RubyObject.java/buggy/org/jruby/RubyObject.java |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.