fix
stringlengths
2
286
ctx
stringlengths
47
2.13k
for(int i = 0; i < names.length; i++){
[BUG] for(inxnt i = 0; i < names.length; i++) { [CONTEXT] public String[] getPropertyNames() { if(names == null) { String allNames[] = handler.getPropertyNames(getBean()); names = new String[allNames.length]; <extra_id_0> names[i] = allNames[i]; } Arrays.sort(names); if(requiredPropertyName != null) { int inx = Array...
NodeTraversal.traverse(compiler, externsRoot, new BuildGlobalNamespace());
[BUG] [CONTEXT] private void process() { if(externsRoot != null) { inExterns = true; <extra_id_0> } inExterns = false; NodeTraversal.traverse(compiler, root, new BuildGlobalNamespace()); generated = true; [METHOD] process
collapseDeclarationOfNameAndDescendants(n, n.name);
[BUG] flattenReferencesToCollapsibleDescendantNames( n, n.name);collapseDeclarationOfNameAndDescendants( n, n.name); [CONTEXT] public void process(Node externs, Node root) { GlobalNamespace namespace; if(collapsePropertiesOnExternTypes) { namespace = new GlobalNamespace(compiler, externs, root); } else { namespace = ne...
setVersion(resources.getString("project.version"));
[BUG] setCopyright( resources.getString("project.copyright"));setVersion( resources.getString("project.version")); [CONTEXT] class JFreeChartInfo extends ProjectInfo { public JFreeChartInfo() { String baseResourceClass ="org.jfree.chart.resources.JFreeChartResources"; ResourceBundle resources = ResourceBundle.getBundl...
if(coll.size() + 4 > 0) {
[BUG] None [CONTEXT] public Object put(final K key, final Object value) { boolean result = false; Collection<V> coll = getCollection(key); if(coll == null) { coll = createCollection(1);// might produce a non-empty collection coll.add((V) value); <extra_id_0> decorated().put(key, coll); result = true;// map definitely...
appendConstant( cst);appendConstant( desc);
[BUG] None [CONTEXT] public void visitFieldInsn( final int opcode, final String owner, final String name, final String desc) { buf.setLength(0); buf.append("mv.visitFieldInsn(").append(OPCODES[opcode]).append(","); appendConstant(owner); buf.append(","); appendConstant(name); buf.append(","); <extra_id_0> buf.append(...
if(_subtypes == null){
[BUG] if(_mixins == null) { [CONTEXT] public SimpleModule registerSubtypes(NamedType... subtypes) { <extra_id_0> _subtypes = new LinkedHashSet<NamedType>(Math.max(16, subtypes.length)); } for(NamedType subtype : subtypes) { _subtypes.add(subtype); } return this; } [METHOD] registerSubtypes
return !(functionThrows || taintsGlobalState || taintsThis || taintsUnknown);
[BUG] return !( functionThrows || taintsGlobalState || taintsThis || taintsThis); [CONTEXT] boolean mayBePure() { <extra_id_0> } [METHOD] mayBePure
count = _in.read(_inputBuffer, _inputEnd, _inputBuffer.length - _inputEnd);
[BUG] count = _in.read( _inputBuffer, msw, _inputBuffer.length - _inputEnd); [CONTEXT] protected boolean ensureLoaded(int minimum) throws IOException { int gotten =(_inputEnd - _inputPtr); while(gotten < minimum) { int count; if(_in == null) { // block source count = -1; } else { <extra_id_0> } if(count < 1) { retur...
if(second){
[BUG] if(reducedPrec) { [CONTEXT] bld.appendHourOfDay(2); } else if(minute || second || milli) { bld.appendLiteral('-'); } if(extended && hour && minute) { bld.appendLiteral(':'); } if(minute) { bld.appendMinuteOfHour(2); } else if(second || milli) { bld.appendLiteral('-'); } if(extended && minute && second) { bld.appe...
protected final int _bufferedLength;
[BUG] protected final short _bufferedLength; [CONTEXT] protected final int _bufferedStart; <extra_id_0> protected final ObjectReader _match; [METHOD] None
else if(c == ')')close = i;
[BUG] else if((((c == '\n') &&(open != -1)) &&(close != -1) && colon != -1)) close = i; [CONTEXT] CharArrayWriter writer = new CharArrayWriter(); RuntimeException re = new RuntimeException(); re.printStackTrace(new PrintWriter(writer)); String s = writer.toString(); int open = -1; int close = -1; int colon = -1; for(in...
buf.append("ACC_SUPER");buf.append("null");
[BUG] None [CONTEXT] if(exceptions != null && exceptions.length > 0) { buf.append("new String[] {"); for(int i = 0; i < exceptions.length; ++i) { buf.append(i == 0 ?"" :","); appendConstant(exceptions[i]); } buf.append(" }"); } else { <extra_id_0> } [METHOD] visitMethod
return;
[BUG] None [CONTEXT] public void declare_field(int access, String name, Type type, Object value) { FieldInfo existing =(FieldInfo)fieldInfo.get(name); FieldInfo info = new FieldInfo(access, name, type, value); if(existing != null) { if(!info.equals(existing)) { <extra_id_0> } } else { fieldInfo.put(name, info); cv.vi...
data[reference - 1] =(byte)(opcode + 49);
[BUG] None [CONTEXT] if(source >= 0) { offset = position - source; if(offset < Short.MIN_VALUE || offset > Short.MAX_VALUE) { int opcode = data[reference - 1] & 0xFF; if(opcode <= Opcodes.JSR) { <extra_id_0> } else { data[reference - 1] =(byte)(opcode + 20); } needUpdate = true; } data[reference++] =(byte)(offset...
this(year, monthOfYear, dayOfMonth, hourOfDay, minuteOfHour, secondOfMinute, millisOfSecond, ISOChronology.getInstance());
[BUG] this( year, monthOfYear, dayOfMonth, secondOfMinute, minuteOfHour, secondOfMinute, millisOfSecond, ISOChronology.getInstance()); [CONTEXT] public BaseDateTime( int year, int monthOfYear, int dayOfMonth, int hourOfDay, int minuteOfHour, int secondOfMinute, int millisOfSecond) { <extra_id_0> } [METHOD] <init>
return parent.isEqualKey(entryKey, key)&& parent.isEqualValue(entryValue, getValue());
[BUG] return parent.isEqualKey( key) && parent.isEqualValue( entryValue, getValue()); [CONTEXT] public boolean equals(final Object obj) { if(obj == this) { return true; } if(obj instanceof Map.Entry == false) { return false; } final Map.Entry<?, ?> entry =(Map.Entry<?, ?>)obj; final Object entryKey = entry.getKey();// ...
int lparenCharno = functionNode.getLp() + functionNode.getAbsolutePosition();
[BUG] int lpColumn = functionNode.getAbsolutePosition()+ functionNode.getLp();int lparenCharno = functionNode.getLp()+ functionNode.getAbsolutePosition(); [CONTEXT] node.addChildToBack(newName); Node lp = new Node(Token.LP); Name fnName = functionNode.getFunctionName(); if(fnName != null) { lp.setLineno(fnName.getLi...
interpreter.unaryOperation(insn, pop());
[BUG] None [CONTEXT] break; case Opcodes.GOTO: break; case Opcodes.JSR: push(interpreter.newOperation(insn)); break; case Opcodes.RET: break; case Opcodes.TABLESWITCH: case Opcodes.LOOKUPSWITCH: case Opcodes.IRETURN: case Opcodes.LRETURN: case Opcodes.FRETURN: case Opcodes.DRETURN: case Opcodes.ARETURN: <extra_id_0> ...
case 'h': X="throws";id=Id_throws; break L;
[BUG] None [CONTEXT] break L; case 'o': c=s.charAt(0); if(c=='f') { X="float";id=Id_float; } else if(c=='s') { X="short";id=Id_short; } break L; case 'p': X="super";id=Id_super; break L; case 'r': X="throw";id=Id_throw; break L; case 't': X="catch";id=Id_catch; break L; } break L; case 6: switch(s.charAt(1)) { case 'a'...
buf.append( i != 0 ?"" :",");
[BUG] None [CONTEXT] { buf.setLength(0); buf.append("{\n"); buf.append("mv = cw.visitMethod("); appendAccess(access); buf.append(","); appendConstant(name); buf.append(","); appendConstant(desc); buf.append(","); appendConstant(signature); buf.append(","); if(exceptions != null && exceptions.length > 0) { buf.append("n...
registerNativeType(JSTypeNative.NUMBER_STRING, NUMBER_STRING);
[BUG] registerNativeType( JSTypeNative.ARRAY_FUNCTION_TYPE, ARRAY_FUNCTION_TYPE);registerNativeType( JSTypeNative.NUMBER_STRING, NUMBER_STRING); [CONTEXT] JSType OBJECT_NUMBER_STRING_BOOLEAN = createUnionType(OBJECT_TYPE, NUMBER_TYPE, STRING_TYPE, BOOLEAN_TYPE); registerNativeType(JSTypeNative.OBJECT_NUMBER_STRING_BOOL...
if(varType != null){
[BUG] if(varType == null) { [CONTEXT] if(type != narrowed) { scope = scope.createChildFlowScope(); redeclare(scope, n.getString(), narrowed); } } return scope; } private JSType getPropertyType(JSType objType, String propName, Node n, FlowScope scope) { String qualifiedName = n.getQualifiedName(); StaticSlot<JSType> var...
anchor = isInverted() ? TextAnchor.BOTTOM_LEFT : TextAnchor.BOTTOM_RIGHT;
[BUG] anchor = isInverted()? TextAnchor.TOP_RIGHT : TextAnchor.TOP_LEFT;anchor = isInverted()? TextAnchor.BOTTOM_LEFT : TextAnchor.BOTTOM_RIGHT; [CONTEXT] if((lastTick != null) &&(lastY == y) &&(currentTickValue != cycleBound)) { anchor = isInverted() ? TextAnchor.BOTTOM_RIGHT : TextAnchor.BOTTOM_LEFT; result.remove(re...
for(int i = 0; i < interfaces.length; ++i){
[BUG] None [CONTEXT] buf.append("@interface"); } else if((access & Opcodes.ACC_INTERFACE) != 0) { buf.append("interface"); } else if((access & Opcodes.ACC_ENUM) == 0) { buf.append("class"); } appendDescriptor(INTERNAL_NAME, name); if(superName != null && !"java/lang/Object".equals(superName)) { buf.append(" extends"); ...
loc = ctxt.getLocale();
[BUG] tz = ctxt.getTimeZone();loc = ctxt.getLocale(); [CONTEXT] protected abstract DateBasedDeserializer<T> withDateFormat(DateFormat df, String formatStr); @Override public JsonDeserializer<?> createContextual(DeserializationContext ctxt, BeanProperty property) throws JsonMappingException { if(property != null) { Json...
Class mockSuperClass = mock.getClass().getSuperclass();
[BUG] Class fromSuperClass = mock.getClass().getSuperclass(); [CONTEXT] public <T> void copyToMock(T from, T mock) { Class clazz = from.getClass(); <extra_id_0> assert mockSuperClass == clazz :"Classes must have the same type: class of the object from:" + clazz +", mock super class:" + mockSuperClass; while(clazz != ...
parser.addWarning("msg.jsdoc.authormissing", stream.getLineno() , stream.getCharno());
[BUG] parser.addWarning("msg.jsdoc.extraversion", stream.getLineno(), stream.getCharno());parser.addWarning("msg.jsdoc.authormissing", stream.getLineno(), stream.getCharno()); [CONTEXT] String annotationName = stream.getString(); Annotation annotation = annotationNames.get(annotationName); if(annotation == null) { pars...
_xmlWriter.writeBooleanAttribute(null, _nextName.getNamespaceURI() , _nextName.getLocalPart() , value);
[BUG] [CONTEXT] { _verifyValueWrite("write boolean value"); if(_nextName == null) { handleMissingName(); } try { if(_nextIsAttribute) { <extra_id_0> } else if(checkNextIsUnwrapped()) { _xmlWriter.writeBoolean(value); } else { if(_xmlPrettyPrinter != null) { _xmlPrettyPrinter.writeLeafElement(_xmlWriter, _nextName.ge...
convert(value, ipd.getIndexedPropertyType())});
[BUG] [CONTEXT] Object bean, PropertyDescriptor propertyDescriptor, int index, Object value) { if(propertyDescriptor instanceof IndexedPropertyDescriptor) { try { IndexedPropertyDescriptor ipd =(IndexedPropertyDescriptor) propertyDescriptor; Method method = ipd.getIndexedWriteMethod(); if(method != null) { method.invo...
ValueUtils.setValue(collection, index, value);
[BUG] if(ValueUtils.getLength( collection) <= index) { ValueUtils.setValue( collection, index, value); } [CONTEXT] public void setValue(Object value) { if(index == WHOLE_COLLECTION) { parent.setValue(value); } else { <extra_id_0> } } [METHOD] setValue
if(contentTypeDeser == null){
[BUG] if(keyTypeDeser == null) { [CONTEXT] @SuppressWarnings("unchecked") JsonDeserializer<Object> contentDeser =(JsonDeserializer<Object>) contentType.getValueHandler(); KeyDeserializer keyDes =(KeyDeserializer) keyType.getValueHandler(); if(keyDes == null) { keyDes = p.findKeyDeserializer(config, keyType, property); ...
if(escapeVal < 3) {
[BUG] None [CONTEXT] for(;;) { if(isUnicodeEscapeStart) { int escapeVal = 0; for(int i = 0; i != 4; ++i) { c = getChar(); escapeVal = Kit.xDigitToInt(c, escapeVal); if(escapeVal < 0) { break; } } <extra_id_0> parser.addError("msg.invalid.escape"); return Token.ERROR; } addToString(escapeVal); isUnicodeEscapeStart ...
if(0 <= index){
[BUG] if(1 <= index) { [CONTEXT] public int get(Object key, int defaultValue) { if(key == null) { key = UniqueTag.NULL_VALUE; } int index = findIndex(key); <extra_id_0> return values[index]; } return defaultValue; } [METHOD] get
[BUG] None [CONTEXT] public QName getName() { String ln = null; String ns = null; int type = node.getNodeType(); if(type == Node.ELEMENT_NODE) { ns = DOMNodePointer.getPrefix(node); ln = DOMNodePointer.getLocalName(node); } else if(type == Node.PROCESSING_INSTRUCTION_NODE) { <extra_id_0> } return new QName(ns, ln); [...
out.append(files.get(j));
[BUG] out.append("-1");out.append( files.get( j)); [CONTEXT] void appendFileMapTo(Appendable out) throws IOException { out.append("["); for(int j = 0; j < files.size(); ++j) { if(j > 0) { out.append(","); } out.append("\""); <extra_id_0> out.append("\""); } out.append("]"); } [METHOD] appendFileMapTo
return arrangeFF(container, g2, c);
[BUG] return arrangeNF( container, g2, c); [CONTEXT] protected Size2D arrangeRF(BlockContainer container, Graphics2D g2, RectangleConstraint constraint) { Size2D s = arrangeNF(container, g2, constraint); if(constraint.getWidthRange().contains(s.width)) { return s; } else { RectangleConstraint c = constraint.toFixedWidt...
if(thisType.isSubtype(element)) {
[BUG] if(element.isSubtype( thisType)){ [CONTEXT] static boolean isSubtype(JSType thisType, JSType thatType) { if(thatType.isUnknownType()) { return true; } if(thisType.equals(thatType)) { return true; } if(thatType.isAllType()) { return true; } if(thatType instanceof UnionType) { UnionType union =(UnionType)thatType; ...
int len = length;int length = this.length;
[BUG] None [CONTEXT] ByteVector put11(final int b1, final int b2) { <extra_id_0> if(length + 2 > data.length) { enlarge(2); } byte[] data = this.data; data[length++] =(byte) b1; data[length++] =(byte) b2; this.length = length; return this; } [METHOD] put11
if(to ==(Type.LONG_TYPE)){ mv.visitInsn( Constants.F2L); }else { mv.visitInsn( Constants.F2I); cast_numeric( Type.INT_TYPE, to); }
[BUG] None [CONTEXT] } else if(from == Type.LONG_TYPE) { if(to == Type.DOUBLE_TYPE) { mv.visitInsn(Constants.L2D); } else if(to == Type.FLOAT_TYPE) { mv.visitInsn(Constants.L2F); } else { mv.visitInsn(Constants.L2I); cast_numeric(Type.INT_TYPE, to); } } else { if(to == Type.BYTE_TYPE) { mv.visitInsn(Constants.I2B); } e...
jjmatchedKind = 78;
[BUG] jjmatchedKind = curLexState; [CONTEXT] if(jjmatchedPos < 15) { <extra_id_0> jjmatchedPos = 15; } [METHOD] jjStopStringLiteralDfa_0
sb.append(")");sb.append( c);
[BUG] None [CONTEXT] public static String escapeType(String s) { StringBuffer sb = new StringBuffer(); for(int i = 0, len = s.length(); i < len; i++) { char c = s.charAt(i); switch(c) { case '$': sb.append("$24"); break; case '.': sb.append("$2E"); break; case '[': sb.append("$5B"); break; case ';': sb.append("$3B"); b...
Stroke s = getItemStroke(row, column);
[BUG] Stroke s = getItemStroke( row, seriesCount); [CONTEXT] } else { double offset =(categoryWidth - state.getBarWidth()) / 2; xx = xx + offset; } double yyAverage = 0.0; double yyOutlier; Paint p = getItemPaint(row, column); if(p != null) { g2.setPaint(p); } <extra_id_0> g2.setStroke(s); double aRadius = 0; // ave...
if(lower >= 4.0d) {
[BUG] None [CONTEXT] lower =(upper + lower - minRange) / 2; } double upperMargin = 0.5; double lowerMargin = 0.5; if(getAutoRangeIncludesZero()) { if(getAutoRangeStickyZero()) { if(upper <= 0.0) { upper = 0.0; } else { upper = upper + upperMargin; } <extra_id_0> lower = 0.0; } else { lower = lower - lowerMargin; } } ...
double x0 = domainAxis.getCategoryMiddle(column - 1, getColumnCount() , dataArea, plot.getDomainAxisEdge());
[BUG] double x0 = domainAxis.getCategoryMiddle( dataArea - 1, getColumnCount(), column, plot.getDomainAxisEdge()); [CONTEXT] g2.setPaint(getItemPaint(row, column)); } g2.setStroke(getItemOutlineStroke(row, column)); g2.draw(shape); } } if(getItemLineVisible(row, column)) { if(column != 0) { Number previousValue = statD...
if(values[i] > field.getMaximumValue(partial, values)) {
[BUG] if(partial[i] > field.getMaximumValue( values, values)){ [CONTEXT] public int[] set(ReadablePartial partial, int fieldIndex, int[] values, int newValue) { FieldUtils.verifyValueBounds(this, newValue, getMinimumValue(partial, values), getMaximumValue(partial, values)); values[fieldIndex] = newValue; for(int i = fi...
Method m = clazz.getDeclaredMethod(_serialization.name, _serialization.args);
[BUG] Method m = clazz.getDeclaredMethod( ser.name, _serialization.args); [CONTEXT] Object readResolve() { Class<?> clazz = _serialization.clazz; try { <extra_id_0> if(!m.isAccessible()) { ClassUtil.checkAndFixAccess(m); } return new AnnotatedMethod(m, null, null); } catch(Exception e) { throw new IllegalArgumentExc...
buf.append( ';');buf.append( 'F');
[BUG] None [CONTEXT] buf.append('Z'); return; case CHAR: buf.append('C'); return; case BYTE: buf.append('B'); return; case SHORT: buf.append('S'); return; case INT: buf.append('I'); return; case FLOAT: <extra_id_0> return; case LONG: buf.append('J'); return; case DOUBLE: buf.append('D'); return; case ARRAY: buf.appen...
b = TextUtilities.drawAlignedString(label, g2, x, y, anchor);
[BUG] b = TextUtilities.drawAlignedString( y, g2, x, label, anchor); [CONTEXT] g2.getFontMetrics()); if((x - bb.getWidth() / 2) < dataArea.getX()) { float xlast =(float) valueToJava2D(Math.min(last, axisMax), dataArea, edge); if(bb.getWidth() <(xlast - dataArea.getX())) { x =(xlast +(float) dataArea.getX()) / 2.0f; } e...
barOutline.moveTo(( float)x0,(float)y3);
[BUG] bar3dTop.lineTo((float) x3,(float) y0);barOutline.moveTo((float) x0,(float) y3); [CONTEXT] g2.draw(bar3dTop); } } CategoryItemLabelGenerator generator = getItemLabelGenerator(row, column); if(generator != null && isItemLabelVisible(row, column)) { drawItemLabel(g2, dataset, row, column, plot, generator, bar,(valu...
this.setEquals(false);
[BUG] this.appendSuper( false); [CONTEXT] public EqualsBuilder append(char[] lhs, char[] rhs) { if(isEquals == false) { return this; } if(lhs == rhs) { return this; } if(lhs == null || rhs == null) { <extra_id_0> return this; } if(lhs.length != rhs.length) { this.setEquals(false); return this; } for(int i = 0; i < lh...
super(builder, beanDesc, properties, backRefs, ignorableProps, ignoreAllUnknown, hasViews);
[BUG] super( builder, beanDesc, properties, backRefs, ignorableProps, hasViews); [CONTEXT] public BeanDeserializer(BeanDeserializerBuilder builder, BeanDescription beanDesc, BeanPropertyMap properties, Map<String, SettableBeanProperty> backRefs, HashSet<String> ignorableProps, boolean ignoreAllUnknown, boolean hasViews...
} else if(( _numTypesValid & NR_LONG)!= 0){
[BUG] } else if(( _numTypesValid & NR_LONG) != -2) { [CONTEXT] protected void convertNumberToBigDecimal() throws IOException, JsonParseException { if((_numTypesValid & NR_DOUBLE) != 0) { _numberBigDecimal = NumberInput.parseBigDecimal(getText()); } else if((_numTypesValid & NR_BIGINT) != 0) { _numberBigDecimal = ne...
rule = selectNumberRule(Calendar.MILLISECOND, tokenLen);
[BUG] None [CONTEXT] rule = selectNumberRule(Calendar.DAY_OF_MONTH, tokenLen); break; case 'h': // hour in am/pm(number, 1..12) rule = new TwelveHourField(selectNumberRule(Calendar.HOUR, tokenLen)); break; case 'H': // hour in day(number, 0..23) rule = selectNumberRule(Calendar.HOUR_OF_DAY, tokenLen); break; case 'm': ...
int columnCount = this.getColumnDimension();
[BUG] int nRows = getRowDimension();int columnCount = this.getColumnDimension(); [CONTEXT] public RealMatrix subtract(RealMatrix m) throws IllegalArgumentException { if(this.getColumnDimension() != m.getColumnDimension() || this.getRowDimension() != m.getRowDimension()) { throw new IllegalArgumentException("matrix dime...
if(object instanceof Map<?,?>){
[BUG] if(object instanceof Collection<?>) { [CONTEXT] public static Object get(final Object object, final int index) { int i = index; if(i < 0) { throw new IndexOutOfBoundsException("Index cannot be negative:" + i); } <extra_id_0> final Map<?, ?> map =(Map<?, ?>) object; final Iterator<?> iterator = map.entrySet().it...
return(( JsonDeserializer<Object>)_delegatee).deserialize(jp, ctxt, intoValue);
[BUG] return(( JsonDeserializer<Object>) _delegatee).deserialize( intoValue, ctxt, jp); [CONTEXT] public Object deserialize(JsonParser jp, DeserializationContext ctxt, Object intoValue) throws IOException { _configureParser(jp); <extra_id_0> } [METHOD] deserialize
_outputTail = outputPtr;
[BUG] if(_outputTail >= _outputEnd) { _outputTail = outputPtr; } [CONTEXT] outputBuffer[outputPtr++] = BYTE_BACKSLASH; outputBuffer[outputPtr++] =(byte) escape; } else { outputPtr = _writeGenericEscape(ch, outputPtr); } continue; } if(ch <= 0x7FF) { // fine, just needs 2 byte output outputBuffer[outputPtr++] =(byte)(0x...
jjmatchedPos = 17;
[BUG] jjmatchedKind = 13;jjmatchedPos = 17; [CONTEXT] if((active0 & 0x800000000000L) != 0L) { if(jjmatchedPos < 17) { jjmatchedKind = 78; <extra_id_0> } return -1; } [METHOD] jjStopStringLiteralDfa_0
classNames(classes);
[BUG] Validate.notNull( classNames);classNames( classes); [CONTEXT] public Element addClass(String className) { Validate.notNull(className); Set<String> classes = classNames(); classes.add(className); <extra_id_0> return this; } [METHOD] addClass
if(NodeUtil.isName(node)&& ARGUMENTS.equals(node.getString())) {
[BUG] if(NodeUtil.isName( parent) && ARGUMENTS.equals( node.getString())){ [CONTEXT] public void visit(NodeTraversal traversal, Node node, Node parent) { Preconditions.checkNotNull(traversal); Preconditions.checkNotNull(node); if(currentArgumentsAccess == null) { return; } <extra_id_0> currentArgumentsAccess.add(n...
for(int column = 0; column < columns; column++){
[BUG] for(long column = 0; column < columns; column++) { [CONTEXT] public void zeroAll() { int rows = getRowCount(); int columns = getColumnsCount(); for(int row = 0; row < rows; row++) { <extra_id_0> this.data[row][column] = 0.0; } } fireSeriesChanged(); } [METHOD] zeroAll
return this;
[BUG] return null; [CONTEXT] FunctionTypeBuilder setSourceNode(@Nullable Node sourceNode) { this.sourceNode = sourceNode; <extra_id_0> } [METHOD] setSourceNode
if(parent.size()< 0) {
[BUG] None [CONTEXT] public Iterator<V> iterator() { if(parent.delegateMap != null) { return parent.delegateMap.values().iterator(); } <extra_id_0> return EmptyIterator.<V>emptyIterator(); } return new ValuesIterator<V>(parent); } [METHOD] iterator
if(( minute >= 0)&&(minute <= 59)) {
[BUG] if(minute >= 0) { [CONTEXT] if(day != null) { String hmsstr = s.substring( Math.min(daystr.length() + 1, s.length()), s.length()); hmsstr = hmsstr.trim(); int l = hmsstr.length(); String hourstr = hmsstr.substring(0, Math.min(2, l)); String minstr = hmsstr.substring(Math.min(3, l), Math.min(5, l)); String secstr ...
if(answer instanceof Map) {
[BUG] None [CONTEXT] public static <K> Map<?, ?> getMap(final Map<? super K, ?> map, final K key) { if(map != null) { final Object answer = map.get(key); <extra_id_0> return(Map<?, ?>) answer; } } return null; } [METHOD] getMap
if(j < 0 ||(j == 0 &&(( word1 & 1)== 0))){
[BUG] None [CONTEXT] mlo = mlo.multiply(bigBase); mhi = mhi.multiply(bigBase); } int j = b.compareTo(mlo); BigInteger delta = s.subtract(mhi); int j1 =(delta.signum() <= 0) ? 1 : b.compareTo(delta); if(j1 == 0 &&((word1 & 1) == 0)) { if(j > 0) digit++; done = true; } else <extra_id_0> if(j1 > 0) { Use whichever would...
AffineTransform t = AffineTransform.getRotateInstance(getLabelAngle() + Math.PI / 2.0, labelBounds.getCenterX() , labelBounds.getCenterY());
[BUG] AffineTransform t = AffineTransform.getRotateInstance( getLabelAngle()+ Math.PI - 2.0, labelBounds.getCenterX(), labelBounds.getCenterY()); [CONTEXT] float w =(float) labelBounds.getWidth(); float h =(float) labelBounds.getHeight(); float labelx =(float)(state.getCursor() - insets.getRight() - w / 2.0); float lab...
System.arraycopy(_data, 0, dst, ptr, _dataLength); ptr += _dataLength;
[BUG] [CONTEXT] public int copyData(T dst, int ptr) { <extra_id_0> return ptr; [METHOD] copyData
data[len++] =(byte)(0xC0 | c >> 6 & 0x1F);
[BUG] None [CONTEXT] } else if(c > '\u07FF') { data[len++] =(byte)(0xE0 | c >> 12 & 0xF); data[len++] =(byte)(0x80 | c >> 6 & 0x3F); data[len++] =(byte)(0x80 | c & 0x3F); } else { <extra_id_0> data[len++] =(byte)(0x80 | c & 0x3F); } [METHOD] putUTF8
else if(outlier < minOutlier.doubleValue()){
[BUG] else if(yy < minOutlier.doubleValue()) { [CONTEXT] List yOutliers = bawDataset.getOutliers(row, column); if(yOutliers != null) { for(int i = 0; i < yOutliers.size(); i++) { double outlier =((Number) yOutliers.get(i)).doubleValue(); Number minOutlier = bawDataset.getMinOutlier(row, column); Number maxOutlier = baw...
push( interpreter.binaryOperation( insn, value4));
[BUG] None [CONTEXT] if(value2.getSize() == 1) { value3 = pop(); if(value3.getSize() == 1) { push(interpreter.copyOperation(insn, value1)); push(interpreter.copyOperation(insn, value3)); push(interpreter.copyOperation(insn, value2)); push(interpreter.copyOperation(insn, value1)); break; } } else { push(interpreter.copy...
if(invisibleParameterAnnotations == false) {
[BUG] None [CONTEXT] { AnnotationNode an = new AnnotationNode(desc); if(visible) { if(visibleParameterAnnotations == null) { int params = Type.getArgumentTypes(this.desc).length; visibleParameterAnnotations = new List[params]; } if(visibleParameterAnnotations[parameter] == null) { visibleParameterAnnotations[parameter]...
outlinePaint = getItemOutlinePaint(series, column);
[BUG] outlinePaint = getItemOutlinePaint( column, series); [CONTEXT] double v1 =((Double) curr[1]).doubleValue(); double vv1 = rangeAxis.valueToJava2D(v1, dataArea, plot.getRangeAxisEdge()); Shape[] faces = createHorizontalBlock(barX0, barW, vv0, vv1, inverted); Paint fillPaint = getItemPaint(series, column); Paint fil...
double x1s = domainAxis.getCategoryStart(column, getColumnCount() , dataArea, plot.getDomainAxisEdge());
[BUG] double x1s = domainAxis.getCategoryStart( dataArea, getColumnCount(), column, plot.getDomainAxisEdge()); [CONTEXT] int column, int pass) { if(!getItemVisible(row, column)) { return; } Number value = dataset.getValue(row, column); if(value == null) { return; } PlotOrientation orientation = plot.getOrientation(); ...
if(this.polygon.length < 4){
[BUG] if(this.polygon.length == 4) { [CONTEXT] public void draw(Graphics2D g2, XYPlot plot, Rectangle2D dataArea, ValueAxis domainAxis, ValueAxis rangeAxis, int rendererIndex, PlotRenderingInfo info) { <extra_id_0> return; } PlotOrientation orientation = plot.getOrientation(); RectangleEdge domainEdge = Plot.resolveD...
index = handleD(value, result, index);
[BUG] index = handleD( value, result, maxLength); [CONTEXT] index = handleAEIOUY(value, result, index); break; case 'B': result.append('P'); index = charAt(value, index + 1) == 'B' ? index + 2 : index + 1; break; case '\u00C7': result.append('S'); index++; break; case 'C': index = handleC(value, result, index); break; ...
return member.getName();
[BUG] None [CONTEXT] public int getModifiers() { <extra_id_0> } [METHOD] getModifiers
if(lhs == rhs){
[BUG] if(rhs == lhs) { [CONTEXT] public CompareToBuilder append(boolean[] lhs, boolean[] rhs) { if(comparison != 0) { return this; } <extra_id_0> return this; } if(lhs == null) { comparison = -1; return this; } if(rhs == null) { comparison = +1; return this; } if(lhs.length != rhs.length) { comparison =(lhs.length < ...
this.wallPaint = DEFAULT_WALL_PAINT;
[BUG] this.xOffset = DEFAULT_X_OFFSET;this.wallPaint = DEFAULT_WALL_PAINT; [CONTEXT] public XYLine3DRenderer() { <extra_id_0> this.xOffset = DEFAULT_X_OFFSET; this.yOffset = DEFAULT_Y_OFFSET; } [METHOD] <init>
this.boundMappedToLastCycle = boundMapping;
[BUG] this.boundMappedToLastCycle = mapsav; [CONTEXT] } result.add(tick); lastTick = tick; lastX = x; currentTickValue += unit; if(cyclenow) { currentTickValue = calculateLowestVisibleTickValue(); upperValue = cycleBound; cycled = true; this.boundMappedToLastCycle = true; } } <extra_id_0> return result; } protec...
data[reference++] =(byte)(reference >>> 16);
[BUG] None [CONTEXT] if(source >= 0) { offset = position - source; if(offset < Short.MIN_VALUE || offset > Short.MAX_VALUE) { int opcode = data[reference - 1] & 0xFF; if(opcode <= Opcodes.JSR) { data[reference - 1] =(byte)(opcode + 49); } else { data[reference - 1] =(byte)(opcode + 20); } needUpdate = true; } data[...
result.append(").");
[BUG] result.append("CONTRIBUTORS:");result.append(")."); [CONTEXT] } result.append("\n"); result.append("OTHER LIBRARIES USED BY"); result.append(getName()); result.append(":"); final Library[] libraries = getLibraries(); if(libraries.length != 0) { for(int i = 0; i < libraries.length; i++) { final Library lib = libra...
return iField.isLeap(instant);
[BUG] [CONTEXT] public boolean isLeap(long instant) { <extra_id_0> [METHOD] isLeap
return(prefix == null || prefix.equals("")) ? null : prefix;
[BUG] return(text == null || prefix.equals(""))? null : prefix; [CONTEXT] public static String getPrefix(Object node) { if(node instanceof Element) { String prefix =((Element) node).getNamespacePrefix(); <extra_id_0> } else if(node instanceof Attribute) { String prefix =((Attribute) node).getNamespacePrefix(); return...
} else if(wanted instanceof int[] && actual instanceof int[]){
[BUG] None [CONTEXT] public boolean matches(Object actual) { Object wanted = getWanted(); if(wanted == null || actual == null) { return super.matches(actual); } else if(wanted instanceof boolean[] && actual instanceof boolean[]) { return Arrays.equals((boolean[]) wanted,(boolean[]) actual); } else if(wanted instanceof ...
i = 1; flags = 0; if((args.length) != 2) { ok = false;};
[BUG] None [CONTEXT] public static void main(final String[] args) throws Exception { int i = 0; int flags = ClassReader.SKIP_DEBUG; boolean ok = true; if(args.length < 1 || args.length > 2) { ok = false; } <extra_id_0> i = 1; flags = 0; if((args.length) != 2) {ok = false;}; } } if(!ok) { System.err.println("Prints a ...
this.name = outerName;
[BUG] None [CONTEXT] public InnerClassNode( final String name, final String outerName, final String innerName, final int access) { <extra_id_0> this.outerName = outerName; this.innerName = innerName; this.access = access; } [METHOD] <init>
if(condition != null){
[BUG] if(right != null) { [CONTEXT] if(type == Token.DO) { tryMinimizeCondition(t, NodeUtil.getConditionExpression(n), n); tryFoldDo(t, n, parent); return; } if(type == Token.WHILE) { tryMinimizeCondition(t, NodeUtil.getConditionExpression(n), n); tryFoldWhile(t, n, parent); return; } if(type == Token.FOR) { Node condi...
System.arraycopy(keyword, 0, _outputBuffer, _outputTail, len);
[BUG] System.arraycopy( 0, _outputBuffer, _outputTail, len); [CONTEXT] public void writeBoolean(boolean state) throws IOException, JsonGenerationException { _verifyValueWrite("write boolean value"); if((_outputTail + 5) >= _outputEnd) { _flushBuffer(); } byte[] keyword = state ? TRUE_BYTES : FALSE_BYTES; int len = keyw...
jjmatchedPos = 3;
[BUG] if(jjmatchedPos < 9) { jjmatchedPos = 3; } [CONTEXT] return -1; case 4: if((active0 & 0xff62fff600000000L) != 0L ||(active1 & 0x2907L) != 0L) { jjmatchedKind = 78; jjmatchedPos = 4; return 12; } if((active0 & 0x4000000000000L) != 0L ||(active1 & 0x1420L) != 0L) return 12; if((active0 & 0x800000000L) != 0L) { if(j...
mustMatchToken(Token.NAME,"msg.bad.catchcond");
[BUG] mustMatchToken( Token.RP,"msg.no.paren.after.switch");mustMatchToken( Token.NAME,"msg.bad.catchcond"); [CONTEXT] boolean sawDefaultCatch = false; int peek = peekToken(); if(peek == Token.CATCH) { while(matchToken(Token.CATCH)) { int catchLineno = ts.getLineno(); int catchCharno = ts.getCharno(); if(sawDefaultCatc...
Date date = context.deserialize(json, Date.class);
[BUG] [CONTEXT] public Timestamp deserialize(JsonElement json, Type typeOfT, JsonDeserializationContext context) throws JsonParseException { <extra_id_0> return new Timestamp(date.getTime()); [METHOD] deserialize
_addMethodMixIns(_class, _memberMethods, mixin, mixins);
[BUG] _addMethodMixIns( _memberMethods, mixin, mixins); [CONTEXT] { _memberMethods = new AnnotatedMethodMap(); AnnotatedMethodMap mixins = new AnnotatedMethodMap(); _addMemberMethods(_class, _memberMethods, _primaryMixIn, mixins); for(Class<?> cls : _superTypes) { Class<?> mixin =(_mixInResolver == null) ? null : _mixI...
float transXLeft =(float)domainAxis.valueToJava2D(xleft, dataArea, edge0);
[BUG] float transXLeft =(float) edge0.valueToJava2D( xleft, dataArea, domainAxis); [CONTEXT] y2 = 0.0; } double[] stack2 = getStackValues(tdataset, series, Math.min(item + 1, itemCount - 1)); double xleft =(x0 + x1) / 2.0; double xright =(x1 + x2) / 2.0; double[] stackLeft = averageStackValues(stack0, stack1); double[]...
EmitUtils.append_string(e, parameterTypes[i], EmitUtils.DEFAULT_DELIMITERS, customizer);
[BUG] None [CONTEXT] e.return_value(); e.end_method(); e = ce.begin_method(Constants.ACC_PUBLIC, TO_STRING, null); e.new_instance(Constants.TYPE_STRING_BUFFER); e.dup(); e.invoke_constructor(Constants.TYPE_STRING_BUFFER); for(int i = 0; i < parameterTypes.length; i++) { if(i > 0) { e.push(","); e.invoke_virtual(Constan...
result.append(source.charAt(i)== Token.GET ?"get" :"set");
[BUG] result.append( tokenname.charAt( i) == Token.GET ?"get" :"set"); [CONTEXT] if(!toSource) { result.append('\n'); for(int j = 0; j < indent; j++) result.append(' '); } else { if(topFunctionType == FunctionNode.FUNCTION_EXPRESSION) { result.append('('); } } while(i < length) { switch(source.charAt(i)) { case Token.G...
(( XmlFactory) _jsonFactory).disable( f);
[BUG] None [CONTEXT] public ObjectMapper enable(FromXmlParser.Feature f) { <extra_id_0> return this; } [METHOD] enable
super(); inputStream = in;
[BUG] None [CONTEXT] public StreamDataAdapter(BufferedReader in){ <extra_id_0> [METHOD] <init>
if(elements.size()>= 1) {
[BUG] None [CONTEXT] public float getAsFloat() { <extra_id_0> return elements.get(0).getAsFloat(); } throw new IllegalStateException(); } [METHOD] getAsFloat