fix stringlengths 2 286 | ctx stringlengths 47 2.13k |
|---|---|
if(!hasNext()) { | [BUG] None [CONTEXT] protected ReferenceEntry<K, V> nextEntry() { checkMod(); <extra_id_0> throw new NoSuchElementException(); } previous = entry; entry = entry.next(); currentKey = nextKey; currentValue = nextValue; nextKey = null; nextValue = null; return previous; } [METHOD] nextEntry |
if(this.maxMiddleIndex >= 0){ | [BUG] if(this.maxMiddleIndex == 0) { [CONTEXT] if(this.minMiddleIndex >= 0) { long s = getDataItem(this.minMiddleIndex).getPeriod().getStart().getTime(); long e = getDataItem(this.minMiddleIndex).getPeriod().getEnd().getTime(); long minMiddle = s +(e - s) / 2; if(middle < minMiddle) { this.minMiddleIndex = index; } } e... |
c.getFirstChild() , output); | [BUG] None [CONTEXT] computeMustDef(n.getFirstChild(), cfgNode, output, conditional); computeMustDef(n.getLastChild(), cfgNode, output, true); return; case Token.HOOK: computeMustDef(n.getFirstChild(), cfgNode, output, conditional); computeMustDef(n.getFirstChild().getNext(), cfgNode, output, true); computeMustDef(n.ge... |
if(!cmd.hasOption(option)) { | [BUG] if(!cmd.hasOption( opt)){ [CONTEXT] private void processProperties(Properties properties) { if(properties == null) { return; } for(Enumeration e = properties.propertyNames(); e.hasMoreElements();) { String option = e.nextElement().toString(); <extra_id_0> Option opt = options.getOption(option); String value = p... |
type = type.restrictByNotNullOrUndefined(); | [BUG] [CONTEXT] void expectCanCast(NodeTraversal t, Node n, JSType type, JSType castType) { castType = castType.restrictByNotNullOrUndefined(); <extra_id_0> if(!type.canAssignTo(castType) && !castType.canAssignTo(type)) { compiler.report( JSError.make(t, n, INVALID_CAST, castType.toString(), type.toString())); regis... |
number = parseNumber(source, special[i], pos); | [BUG] Number im = parseNumber( source, getRealFormat(), pos);number = parseNumber( source, special[i], pos); [CONTEXT] private Number parseNumber(String source, NumberFormat format, ParsePosition pos) { int startIndex = pos.getIndex(); Number number = format.parse(source, pos); int endIndex = pos.getIndex(); if(startIn... |
populated = true; | [BUG] None [CONTEXT] public boolean recordInterface() { if(!hasAnySingletonTypeTags() && !currentInfo.isConstructor() && !currentInfo.isInterface()) { currentInfo.setInterface(true); <extra_id_0> return true; } else { return false; } } [METHOD] recordInterface |
jjmatchedKind = 78; | [BUG] jjmatchedPos = 17;jjmatchedKind = 78; [CONTEXT] if(jjmatchedPos < 17) { <extra_id_0> jjmatchedPos = 17; } [METHOD] jjStopStringLiteralDfa_0 |
return new MonthDay(calendar.get(Calendar.MONTH)+ 1, calendar.get(Calendar.DAY_OF_MONTH)); | [BUG] return new MonthDay( calendar.get( Calendar.MONTH) , calendar.get( Calendar.DAY_OF_MONTH)); [CONTEXT] public static MonthDay fromCalendarFields(Calendar calendar) { if(calendar == null) { throw new IllegalArgumentException("The calendar must not be null"); } <extra_id_0> } [METHOD] fromCalendarFields |
public static final CategoryLabelPositions DOWN_45 = createDownRotationLabelPositions(Math.PI / 4.0); | [BUG] public static final CategoryLabelPositions DOWN_45 = createDownRotationLabelPositions( Math.PI / 1.0d); [CONTEXT] <extra_id_0> [METHOD] None |
iHourOfHalfday =(f = fields.hourOfHalfday) != null ? f : super.hourOfHalfday(); | [BUG] iMinuteOfDay =(f = fields.minuteOfDay) != null ? f : super.minuteOfDay();iHourOfHalfday =(f = fields.hourOfHalfday) != null ? f : super.hourOfHalfday(); [CONTEXT] iYears =(f = fields.years) != null ? f : super.years(); iCenturies =(f = fields.centuries) != null ? f : super.centuries(); iEras=(f = fields.eras... |
if(t == JsonToken.VALUE_NUMBER_INT || t == JsonToken.VALUE_NUMBER_FLOAT){ | [BUG] if(JsonToken.VALUE_NUMBER_FLOAT == JsonToken.VALUE_NUMBER_INT || t == t) { [CONTEXT] { if((jp.getCurrentToken() == JsonToken.VALUE_STRING) && ctxt.isEnabled(DeserializationFeature.ACCEPT_EMPTY_STRING_AS_NULL_OBJECT)) { if(jp.getText().length() == 0) { return null; } } if(!ctxt.isEnabled(DeserializationFeature.ACC... |
buf.append(" +"); | [BUG] None [CONTEXT] if((access & Opcodes.ACC_VARARGS) != 0 &&(access & ACCESS_CLASS) == 0 &&(access & ACCESS_FIELD) == 0) { if(!first) { <extra_id_0> } buf.append("ACC_VARARGS"); first = false; } [METHOD] appendAccess |
intersectElements(filterForSelf(elements, candidates)); | [BUG] [CONTEXT] private Elements select() { tq.consumeWhitespace(); if(tq.matchesAny(combinators)) { // if starts with a combinator, use root as elements elements.add(root); combinator(tq.consume().toString()); } else { addElements(findElements()); // chomp first element matcher off queue } while(!tq.isEmpty()) { bool... |
handleFunction(n); | [BUG] handleStmt( n);handleFunction( n); [CONTEXT] return; case Token.SWITCH: handleSwitch(n); return; case Token.CASE: handleCase(n); return; case Token.DEFAULT: handleDefault(n); return; case Token.BLOCK: case Token.SCRIPT: handleStmtList(n); return; case Token.FUNCTION: <extra_id_0> return; case Token.EXPR_RESULT:... |
obuilder.withId(option1.getId()); | [BUG] obuilder.withId( option1.getOpt()); [CONTEXT] public static Option option(final org.apache.commons.cli.Option option1){ final DefaultOptionBuilder obuilder = new DefaultOptionBuilder(); obuilder.withRequired(option1.isRequired()); final String shortName = option1.getOpt(); if(shortName!=null && !"".equals(shortNa... |
if(_outputTail >= _outputEnd){ | [BUG] None [CONTEXT] public void writeString(char[] text, int offset, int len) throws IOException, JsonGenerationException { _verifyValueWrite("write text value"); <extra_id_0> _flushBuffer(); } _outputBuffer[_outputTail++] = BYTE_QUOTE; if(len <= _outputMaxContiguous) { if((_outputTail + len) > _outputEnd) { // call... |
iPrinter = printer; | [BUG] iPrinter = iPrinter; [CONTEXT] public PeriodFormatter( PeriodPrinter printer, PeriodParser parser) { super(); <extra_id_0> iParser = parser; iLocale = null; iParseType = null; } [METHOD] <init> |
if(( access &(ACCESS_CLASS))== 0) { buf.append("ACC_SYNCHRONIZED"); }else { buf.append("ACC_SUPER"); } | [BUG] None [CONTEXT] pw.flush(); } void appendAccess(final int access) { boolean first = true; <extra_id_0> buf.append("ACC_PUBLIC"); first = false; } if((access & Opcodes.ACC_PRIVATE) != 0) { buf.append("ACC_PRIVATE"); first = false; } if((access & Opcodes.ACC_PROTECTED) != 0) { buf.append("ACC_PROTECTED"); fir... |
shortOpts.put(key, opt); | [BUG] [CONTEXT] public Options addOption(Option opt) { String key = opt.getKey(); if(opt.hasLongOpt()) { longOpts.put(opt.getLongOpt(), opt); } if(opt.isRequired()){ if( requiredOpts.contains(key)){ requiredOpts.remove( requiredOpts.indexOf(key)); } requiredOpts.add(key); } <extra_id_0> return this; [METHOD] addOpti... |
char swap = buf[leftIdx]; | [BUG] char swap = destination[leftIdx]; [CONTEXT] public StrBuilder reverse() { if(size == 0) { return this; } int half = size / 2; char[] buf = buffer; for(int leftIdx = 0, rightIdx = size - 1; leftIdx < half; leftIdx++,rightIdx--) { <extra_id_0> buf[leftIdx] = buf[rightIdx]; buf[rightIdx] = swap; } return this; } [... |
compiler.reportCodeChange(); break; | [BUG] None [CONTEXT] Node block; if(!NodeUtil.isStatementBlock(parent)) { block = new Node(Token.BLOCK); parent.replaceChild(n, block); block.addChildToFront(tryBlock); } else { parent.replaceChild(n, tryBlock); block = parent; } if(finallyBlock != null) { block.addChildAfter(finallyBlock, tryBlock); } <extra_id_0> ... |
instant = iJulianField.add(instant, value); | [BUG] instant = julianField.add( instant, value); [CONTEXT] public long add(long instant, long value) { if(instant >= iCutover) { instant = iGregorianField.add(instant, value); if(instant < iCutover) { if(instant + iGapDuration < iCutover) { instant = gregorianToJulian(instant); } } } else { <extra_id_0> if(instant >... |
if(signature.charAt(0)== '<'){ | [BUG] None [CONTEXT] public void accept(final SignatureVisitor v) { String signature = this.signature; int len = signature.length(); int pos; char c; <extra_id_0> pos = 2; do { int end = signature.indexOf(':', pos); v.visitFormalTypeParameter(signature.substring(pos - 1, end)); pos = end + 1; c = signature.charAt(pos... |
if(value != null){ | [BUG] if(enumType == null) { [CONTEXT] private EnumType getEnumType(String name, Node parent, Node value, JSType elementsType) { EnumType enumType = null; <extra_id_0> if(value.getType() == Token.OBJECTLIT) { enumType = typeRegistry.createEnumType(name, elementsType); Node key = value.getFirstChild(); while(key != nu... |
if(n.hasChildren()){ | [BUG] if(value.hasChildren()) { [CONTEXT] <extra_id_0> parent.removeChild(n); Node value = n.getFirstChild(); n.removeChild(value); Node replacement = new Node(Token.ASSIGN, n, value); gramps.replaceChild(parent, new Node(Token.EXPR_RESULT, replacement)); } else { if(NodeUtil.isStatementBlock(gramps)) { gramps.removeC... |
if(moment.n <= 3 || variance < 10E-20){ | [BUG] if(moment.n <= 3 || variance > 10E-20) { [CONTEXT] public double getResult() { double kurtosis = Double.NaN; if(moment.getN() > 3) { double variance = moment.m2 /(double)(moment.n - 1); <extra_id_0> kurtosis = 0.0; } else { double n =(double) moment.n; kurtosis =(n *(n + 1) * moment.m4 - 3 * moment.m2 * moment.... |
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; } if(ok &&"-debug".equals(args[0])) { i = 1; flags = 0; <extra_id_0> ok = false; } if(!ok) { System.err.println("P... |
Math.min(index, this.tickUnits.size() - 1)); | [BUG] Math.min( index, this.tickUnits.size()- index)); [CONTEXT] public TickUnit getLargerTickUnit(TickUnit unit) { int index = Collections.binarySearch(this.tickUnits, unit); if(index >= 0) { index = index + 1; } else { index = -index; } return(TickUnit) this.tickUnits.get( <extra_id_0> } [METHOD] getLargerTickUnit |
[Delete] | [BUG] None [CONTEXT] if((access & Opcodes.ACC_INTERFACE) != 0) { if(!first) { buf.append(" +"); } buf.append("ACC_INTERFACE"); first = false; } if((access & Opcodes.ACC_STRICT) != 0) { if(!first) { buf.append(" +"); } buf.append("ACC_STRICT"); first = false; } if((access & Opcodes.ACC_SYNTHETIC) != 0) { <extra_id_0> ... |
if(sort != t.sort){ | [BUG] None [CONTEXT] public boolean equals(final Object o) { if(this == o) { return true; } if(!(o instanceof Type)) { return false; } Type t =(Type) o; <extra_id_0> return false; } if(sort == OBJECT || sort == ARRAY) { if(len != t.len) { return false; } for(int i = off, j = t.off, end = i + len; i < end; i++, j++) {... |
else if(( yyyy % 400)== 0){ | [BUG] else if(yyyy % 400) { [CONTEXT] public static boolean isLeapYear(final int yyyy) { if((yyyy % 4) != 0) { return false; } <extra_id_0> return true; } else if((yyyy % 100) == 0) { return false; } else { return true; } } [METHOD] isLeapYear |
[BUG] None [CONTEXT] public LookupSwitchInsnNode( final LabelNode dflt, final int[] keys, final LabelNode[] labels) { super(Opcodes.LOOKUPSWITCH); this.dflt = dflt; this.keys = new ArrayList(keys == null ? 0 : keys.length); this.labels = new ArrayList(labels == null ? 0 : labels.length); if(keys != null) { for(int i = ... | |
name += firstChars[pos]; | [BUG] name += reservedCharacters[pos]; [CONTEXT] String generateNextName() { while(true) { String name = prefix; int i = nameCount; if(name.isEmpty()) { int pos = i % firstChars.length; <extra_id_0> i /= firstChars.length; } while(i > 0) { i--; int pos = i % nonFirstChars.length; name += nonFirstChars[pos]; i /= nonF... |
private final Map<String, String> declarations = Maps.newHashMap(); | [BUG] private final Map<String, String> declarations = null; [CONTEXT] static class InlineRenamer implements Renamer { <extra_id_0> private final Supplier<String> uniqueIdSupplier; private final String namePrefix; private final boolean removeConstness; InlineRenamer( [METHOD] None |
e.successor = successor.successors.successor; | [BUG] None [CONTEXT] void visitSubroutine(final Label JSR, final long id, final int nbSubroutines) { if(JSR != null) { if((status & VISITED) != 0) { return; } status |= VISITED; if((status & RET) != 0) { if(!inSameSubroutine(JSR)) { Edge e = new Edge(); e.info = inputStackTop; <extra_id_0> e.next = successors; succes... |
if(valueToFind == array[i]){ | [BUG] if(valueToFind == subarray[i]) { [CONTEXT] public static int indexOf(boolean[] array, boolean valueToFind, int startIndex) { if(ArrayUtils.isEmpty(array)) { return INDEX_NOT_FOUND; } if(startIndex < 0) { startIndex = 0; } for(int i = startIndex; i < array.length; i++) { <extra_id_0> return i; } } return INDEX_N... |
return median; | [BUG] return x; [CONTEXT] public double getMedian() { <extra_id_0> } [METHOD] getMedian |
bar = new Rectangle2D.Double(barL0, barW0, barLength, state.getBarWidth()); | [BUG] bar = new Rectangle2D.Double( xOffset, barW0, barLength, state.getBarWidth()); [CONTEXT] state, row, column); double[] barL0L1 = calculateBarL0L1(value); if(barL0L1 == null) { return;// the bar is not visible } RectangleEdge edge = plot.getRangeAxisEdge(); double transL0 = rangeAxis.valueToJava2D(barL0L1[0], adju... |
jjmatchedKind = 78; | [BUG] jjmatchedPos = 12;jjmatchedKind = 78; [CONTEXT] jjmatchedPos = 5; } return -1; } if((active0 & 0x1000000000L) != 0L) { if(jjmatchedPos < 4) { jjmatchedKind = 78; jjmatchedPos = 4; } return -1; } if((active0 & 0xfc62ffc400000000L) != 0L ||(active1 & 0x2003L) != 0L) { <extra_id_0> jjmatchedPos = 6; return 12; } r... |
e.dup(); | [BUG] None [CONTEXT] if(skipEquals && bucket.size() == 1) { if(skipEquals) e.pop(); callback.processCase((String)bucket.get(0), end); } else { for(Iterator it = bucket.iterator(); it.hasNext();) { String string =(String)it.next(); if(next != null) { e.mark(next); } if(it.hasNext()) { <extra_id_0> } e.push(string); e.... |
protected int iMaxDigits; | [BUG] protected short iMaxDigits; [CONTEXT] static class Fraction implements DateTimePrinter, DateTimeParser { private final DateTimeFieldType iFieldType; protected int iMinDigits; <extra_id_0> protected Fraction(DateTimeFieldType fieldType, int minDigits, int maxDigits) { super(); iFieldType = fieldType; [METHOD] No... |
double radius = dataset.getYValue(seriesIndex, i); | [BUG] double radius = dataset.getYValue( seriesIndex, seriesIndex); [CONTEXT] int seriesIndex) { Polygon poly = new Polygon(); int numPoints = dataset.getItemCount(seriesIndex); for(int i = 0; i < numPoints; i++) { double theta = dataset.getXValue(seriesIndex, i); <extra_id_0> Point p = plot.translateValueThetaRadius... |
offset = TarUtils.getNameBytes(userName, outbuf, offset, UNAMELEN); | [BUG] offset = TarUtils.getNameBytes( magic, outbuf, offset, UNAMELEN); [CONTEXT] offset = TarUtils.getOctalBytes(mode, outbuf, offset, MODELEN); offset = TarUtils.getOctalBytes(userId, outbuf, offset, UIDLEN); offset = TarUtils.getOctalBytes(groupId, outbuf, offset, GIDLEN); offset = TarUtils.getLongOctalBytes(size, o... |
long instant = fieldType.getField(getChronology()).set(getLocalMillis() , value); | [BUG] [CONTEXT] public LocalDateTime withField(DateTimeFieldType fieldType, int value) { if(fieldType == null) { throw new IllegalArgumentException("Field must not be null"); } <extra_id_0> return withLocalMillis(instant); [METHOD] withField |
throw new AnalyzerException( null,"an object reference", value); | [BUG] None [CONTEXT] case LRETURN: expected = BasicValue.LONG_VALUE; break; case DNEG: case D2I: case D2F: case D2L: case DRETURN: expected = BasicValue.DOUBLE_VALUE; break; case GETFIELD: expected = newValue(Type.getObjectType(((FieldInsnNode) insn).owner)); break; case CHECKCAST: if(!((BasicValue) value).isReference(... |
StringBuffer buff = new StringBuffer(defaultSyntaxPrefix).append(app).append(""); | [BUG] StringBuffer buff = new StringBuffer( defaultNewLine).append( app).append(""); [CONTEXT] } public void printUsage(PrintWriter pw, int width, String app, Options options) { <extra_id_0> final Collection processedGroups = new ArrayList(); Option option; for(Iterator i = options.getOptions().iterator(); i.has... |
ungetChar(c2); | [BUG] ungetChar( sourceEnd); [CONTEXT] return JsDocToken.STRING; } else { do { c1 = c2; c2 = getChar(); if(c1 == '.' && c2 == '<') { ungetChar(c2); ungetChar(c1); this.string = getStringFromBuffer(); stringBufferTop = 0; return JsDocToken.STRING; } else { if(isJSDocString(c2)) { addToString(c1); } else { <extra_id_0> ... |
super.printStackTrace(); | [BUG] None [CONTEXT] public final void printPartialStackTrace(PrintWriter out) { <extra_id_0> } [METHOD] printPartialStackTrace |
[BUG] None [CONTEXT] public Value merge(final Value v, final Value w) { SourceValue dv =(SourceValue) v; SourceValue dw =(SourceValue) w; if(dv.insns instanceof SmallSet && dw.insns instanceof SmallSet) { <extra_id_0> if(s == dv.insns && dv.size == dw.size) { return v; } else { return new SourceValue(Math.min(dv.size... | |
bar = new Rectangle2D.Double(barW0, barL0, state.getBarWidth() , barLength); | [BUG] bar = new Rectangle2D.Double( x3, barL0, state.getBarWidth(), barLength); [CONTEXT] } RectangleEdge edge = plot.getRangeAxisEdge(); double transL0 = rangeAxis.valueToJava2D(barL0L1[0], adjusted, edge); double transL1 = rangeAxis.valueToJava2D(barL0L1[1], adjusted, edge); double barL0 = Math.min(transL0, transL1);... |
[BUG] None [CONTEXT] protected Property getProperty(String name) { if(!properties.containsKey(name)) { <extra_id_0> } return properties.get(name); [METHOD] getProperty | |
return iValue; | [BUG] return object; [CONTEXT] public T getValue() { <extra_id_0> } [METHOD] getValue |
return new ConstantTransformer<I, O>(constantToReturn); | [BUG] return new ConstantTransformer<I, O>( iConstant); [CONTEXT] public static <I, O> Transformer<I, O> constantTransformer(final O constantToReturn) { if(constantToReturn == null) { return nullTransformer(); } <extra_id_0> } [METHOD] constantTransformer |
if(acc.nextByte() != matchStr.charAt(i)) { | [BUG] if(acc.nextByte()> matchStr.charAt( i)){ [CONTEXT] private static MatchStrength tryMatch(InputAccessor acc, String matchStr, MatchStrength fullMatchStrength) throws IOException { for(int i = 0, len = matchStr.length(); i < len; ++i) { if(!acc.hasMoreBytes()) { return MatchStrength.INCONCLUSIVE; } <extra_id_0> r... |
return Array.getLength(object)== 0; | [BUG] return Array.getLength( object) == 6; [CONTEXT] public static boolean sizeIsEmpty(final Object object) { if(object == null) { return true; } else if(object instanceof Collection<?>) { return((Collection<?>) object).isEmpty(); } else if(object instanceof Iterable<?>) { return IterableUtils.isEmpty((Iterable<?>) ob... |
_ctorParameters = _ctorParameters.withValue(_ctorParameters.value.withAnnotations(ann)); | [BUG] _ctorParameters = _ctorParameters.value.withValue( _ctorParameters.withAnnotations( ann)); [CONTEXT] public void mergeAnnotations(boolean forSerialization) { if(forSerialization) { if(_getters != null) { AnnotationMap ann = _mergeAnnotations(0, _getters, _fields, _ctorParameters, _setters); _getters = _getters.wi... |
INDENT_OUTPUT(false), | [BUG] INDENT_OUTPUT( true) , [CONTEXT] <extra_id_0> [METHOD] None |
return _valueInstantiator.createUsingDelegate(ctxt, _delegateDeserializer.deserialize(jp, ctxt)); | [BUG] return jp.createUsingDelegate( ctxt, _delegateDeserializer.deserialize( _valueInstantiator, ctxt)); [CONTEXT] protected Object deserializeWithUnwrapped(JsonParser jp, DeserializationContext ctxt) throws IOException, JsonProcessingException { if(_delegateDeserializer != null) { <extra_id_0> } if(_propertyBasedCr... |
int half = len / 2; | [BUG] None [CONTEXT] private int lower(int lo, int hi, int val) { int len = hi - lo; while(len > 0) { <extra_id_0> int mid= lo + half; if(compare(mid, val) < 0) { lo = mid + 1; len = len - half -1; } else { len = half; } } return lo; } [METHOD] lower |
double as = stream.readDouble(); | [BUG] int type = stream.readInt();double as = stream.readDouble(); [CONTEXT] double h = stream.readDouble(); result = new Rectangle2D.Double(x, y, w, h); } else if(c.equals(Ellipse2D.class)) { double x = stream.readDouble(); double y = stream.readDouble(); double w = stream.readDouble(); double h = stream.readDouble();... |
value =(( value << 3)+(value << 1)) + text.charAt(i++)- '0'; | [BUG] value =(( value << 3) +(value | 1))+ text.charAt( i++) - '0'; [CONTEXT] if(length >= 9) { value = Integer.parseInt(text.substring(position, position += length)); } else { int i = position; if(negative) { i++; } try { value = text.charAt(i++) - '0'; } catch(StringIndexOutOfBoundsException e) { return ~position; }... |
return next(); | [BUG] [CONTEXT] if(current.getNext() == null) { current = ancestors.peek(); if(current.getType() == Token.FUNCTION) { return next(); } } else { current = current.getNext(); ancestors.push(current); if(current.getType() == Token.FUNCTION) { return next(); } while(current.hasChildren()) { current = current.getFirstChild... |
if(expLen == 0){ | [BUG] if(intLen == 0) { [CONTEXT] ch =(int) _inputBuffer[ptr++]; if(ch == INT_MINUS || ch == INT_PLUS) { // yup, skip for now if(ptr >= inputLen) { break dummy_loop; } ch =(int) _inputBuffer[ptr++]; } while(ch <= INT_9 && ch >= INT_0) { ++expLen; if(ptr >= inputLen) { break dummy_loop; } ch =(int) _inputBuffer[ptr++]; ... |
this.workingCalendar.setTime(date); | [BUG] this.workingCalendar.getTime(); [CONTEXT] public long getTime(Date date) { long result = date.getTime(); if(this.adjustForDaylightSaving) { <extra_id_0> this.workingCalendarNoDST.set( this.workingCalendar.get(Calendar.YEAR), this.workingCalendar.get(Calendar.MONTH), this.workingCalendar.get(Calendar.DATE), this... |
if(nameNode != null){ | [BUG] if(nameNode == null) { [CONTEXT] private void visitBreakOrContinue(Node node) { Node nameNode = node.getFirstChild(); <extra_id_0> String name = nameNode.getString(); Preconditions.checkState(name.length() != 0); LabelInfo li = getLabelInfo(name); if(li != null) { String newName = getNameForId(li.id); li.refere... |
properties[i] = constructCreatorProperty(ctxt, beanDesc, name, i, param, injectId); | [BUG] properties[i] = constructCreatorProperty( ctxt, beanDesc, i, name, param, injectId); [CONTEXT] AnnotatedParameter nonAnnotatedParam = null; CreatorProperty[] properties = new CreatorProperty[argCount]; int namedCount = 0; int injectCount = 0; for(int i = 0; i < argCount; ++i) { AnnotatedParameter param = factory.... |
return iStartMillis; | [BUG] return serialVersionUID; [CONTEXT] public long getStartMillis() { <extra_id_0> } [METHOD] getStartMillis |
e.getfield(CONSTRUCTED_FIELD); | [BUG] None [CONTEXT] public int getIndex(MethodInfo method) { return((Integer)indexes.get(method)).intValue(); } public void emitCallback(CodeEmitter e, int index) { emitCurrentCallback(e, index); } public Signature getImplSignature(MethodInfo method) { return rename(method.getSignature(),((Integer)positions.get(method... |
if(secondArgument.getType() != Token.STRING){ compiler.report(JSError.make(t, secondArgument, STRING_LITERAL_EXPECTED_ERROR, Token.name(secondArgument.getType()))); return; } | [BUG] compiler.report(com.google.javascript.jscomp.JSError.make(t, secondArgument, com.google.javascript.jscomp.ObjectPropertyStringPreprocess.STRING_LITERAL_EXPECTED_ERROR, com.google.javascript.rhino.Token.name(secondArgument.getType()))); return; [CONTEXT] if(n.getChildCount() != 3) { compiler.report(JSError.make(t,... |
startIndex = 0; | [BUG] None [CONTEXT] } } return false; } protected void prepareForIndividualProperty(String name) { targetReady = true; empty = true; String names[] = propertyNodePointer.getPropertyNames(); if(!reverse) { if(startPropertyIndex == PropertyPointer.UNSPECIFIED_PROPERTY) { startPropertyIndex = 0; } if(startIndex == NodePo... |
code.append('X'); | [BUG] code.append( '0');code.append( 'X'); [CONTEXT] (FRONTV.indexOf(local.charAt(n + 1)) >= 0)) { code.append('S'); break; // CI,CE,CY -> S } if(isPreviousChar(local, n, 'S') && isNextChar(local, n, 'H')){ // SCH->sk code.append('K'); break; } if(isNextChar(local, n, 'H')) { // detect CH if((n == 0) &&(wdsz >= 3) && i... |
out.write('r'); | [BUG] out.write( '\r');out.write( 'r'); [CONTEXT] break; case '\n': out.write('\\'); out.write('n'); break; case '\t': out.write('\\'); out.write('t'); break; case '\f': out.write('\\'); out.write('f'); break; case '\r': out.write('\\'); <extra_id_0> break; default : if(ch > 0xf) { out.write("\\u00" + hex(ch)); } els... |
double x2 = dataset.getXValue(series, Math.min(item + 1, itemCount - 1)); | [BUG] double x2 = dataset.getXValue( series, Math.min( item + 1, series - 1)); [CONTEXT] plot.getRangeAxisEdge()); double x0 = dataset.getXValue(series, Math.max(item - 1, 0)); double y0 = dataset.getYValue(series, Math.max(item - 1, 0)); if(Double.isNaN(y0)) { y0 = 0.0; } double transX0 = domainAxis.valueToJava2D(x0,... |
cv.visitInnerClass( name, access, innerName, outerName); | [BUG] None [CONTEXT] public void visitInnerClass( final String name, final String outerName, final String innerName, final int access) { checkState(); CheckMethodAdapter.checkInternalName(name,"class name"); if(outerName != null) { CheckMethodAdapter.checkInternalName(outerName,"outer class name"); } if(innerName != nu... |
System.arraycopy(converters, 0, copy, 0, length); | [BUG] System.arraycopy( converters, -8, copy, -8, length); [CONTEXT] copy[j] = converters[j]; } else { copy[j] = converter; } } if(removed != null) { removed[0] = existing; } return new ConverterSet(copy); } } Converter[] copy = new Converter[length + 1]; <extra_id_0> copy[length] = converter; if(removed != null) { r... |
double yright =(y1 + y2)/ 2.0 + stackRight[0]; | [BUG] float yright =(y1 + y2) / 2.0 + stackRight[0]; [CONTEXT] left.lineTo(transXLeft, transStackLeft); left.lineTo(transXLeft, transYLeft); left.closePath(); } float transStackRight =(float) rangeAxis.valueToJava2D( adjStackRight[0], dataArea, edge1); if(y2 >= 0.0) { right.moveTo(transX1, transStack1); right.lineTo(tr... |
this.signature = signature;this.start = start; | [BUG] None [CONTEXT] public LocalVariableNode( final String name, final String desc, final String signature, final LabelNode start, final LabelNode end, final int index) { this.name = name; this.desc = desc; this.signature = signature; <extra_id_0> this.end = end; this.index = index; } [METHOD] <init> |
this.plotImages = flag; | [BUG] if(this.plotLines != flag) { this.plotImages = flag; } [CONTEXT] public void setPlotImages(boolean flag) { if(this.plotImages != flag) { <extra_id_0> notifyListeners(new RendererChangeEvent(this)); } } [METHOD] setPlotImages |
addSymbolUse(propNameNode.getString() , t.getModule() , PROPERTY); | [BUG] addSymbolUse( t.getString(), propNameNode.getModule(), PROPERTY); [CONTEXT] for(Node propNameNode = n.getFirstChild(); propNameNode != null; propNameNode = propNameNode.getNext().getNext()) { if(propNameNode.getType() == Token.STRING && !propNameNode.isQuotedString()) { <extra_id_0> } } [METHOD] visit |
} else if(value == falseValue){ | [BUG] } else if(value <= falseValue) { [CONTEXT] public static boolean toBoolean(int value, int trueValue, int falseValue) { if(value == trueValue) { return true; <extra_id_0> return false; } throw new IllegalArgumentException("The Integer did not match either specified value"); } [METHOD] toBoolean |
n = matrix.getColumnDimension(); | [BUG] n = matrix.getRowDimension(); [CONTEXT] private int m; private int n; public QRDecompositionImpl(RealMatrix matrix) { m = matrix.getRowDimension(); <extra_id_0> qr = matrix.getData(); rDiag = new double[n]; for(int minor = 0; minor < Math.min(m, n); minor++) { [METHOD] <init> |
prop.deserializeSetAndReturn(jp, ctxt, builder); | [BUG] [CONTEXT] final SettableBeanProperty[] props = _orderedProperties; int i = 0; final int propCount = props.length; while(true) { if(jp.nextToken() == JsonToken.END_ARRAY) { return builder; } if(i == propCount) { break; } SettableBeanProperty prop = props[i]; ++i; if(prop != null) { // normal case if(activeView ==... |
throw new IllegalArgumentException(""); | [BUG] None [CONTEXT] if(forcePublic != null) { forcePublic.addAll(MethodWrapper.createSet(interfaceMethods)); } methods.addAll(interfaceMethods); } CollectionUtils.filter(methods, new RejectModifierPredicate(Constants.ACC_STATIC)); CollectionUtils.filter(methods, new VisibilityPredicate(superclass, true)); CollectionUt... |
_outputTail = b64variant.encodeBase64Chunk(b24, _outputBuffer, _outputTail); | [BUG] _outputTail = b64variant.encodeBase64Chunk( b24, _outputTail); [CONTEXT] if(inputPtr > lastFullOffset) { inputEnd = _readMore(data, readBuffer, inputPtr, inputEnd, bytesLeft); inputPtr = 0; if(inputEnd < 3) { // required to try to read to have at least 3 bytes break; } lastFullOffset = inputEnd-3; } if(_outputTai... |
if(zone == DateTimeZone.UTC && iWithUTC != null){ | [BUG] if(zone == DateTimeZone.UTC && chrono != null) { [CONTEXT] } public Chronology withZone(DateTimeZone zone) { if(zone == null) { zone = DateTimeZone.getDefault(); } if(zone == getZone()) { return this; } <extra_id_0> return iWithUTC; } DateTime lowerLimit = iLowerLimit; if(lowerLimit != null) { MutableDateTime... |
deser = mod.modifyArrayDeserializer(config, type, beanDesc, deser); | [BUG] deser = mod.modifyArrayDeserializer( config, beanDesc, deser); [CONTEXT] if(contentDeser == null) { Class<?> raw = elemType.getRawClass(); if(elemType.isPrimitive()) { return PrimitiveArrayDeserializers.forType(raw); } else if(raw == String.class) { return StringArrayDeserializer.instance; } } if(deser == null) {... |
final Number answer = getNumber(map, key); | [BUG] final Number answer = getNumber( map); [CONTEXT] public static <K> Float getFloat(final Map<? super K, ?> map, final K key) { <extra_id_0> if(answer == null) { return null; } if(answer instanceof Float) { return(Float) answer; } return Float.valueOf(answer.floatValue()); } [METHOD] getFloat |
v = OBJECT | cw.addType("java/lang/Object"); | [BUG] None [CONTEXT] if((u & BASE_KIND) == OBJECT) { v =(t & DIM) | OBJECT | cw.getMergedType(t & BASE_VALUE, u & BASE_VALUE); } else { <extra_id_0> } [METHOD] merge |
if(newValue == value){ | [BUG] if(v == value) { [CONTEXT] public Linked<T> withValue(T newValue) { <extra_id_0> return this; } return new Linked<T>(newValue, next, explicitName, isVisible, isMarkedIgnored); } [METHOD] withValue |
ReadableObjectId roid = ctxt.findObjectId(id, _objectIdReader.generator); | [BUG] ReadableObjectId roid = ctxt.findObjectId( id); [CONTEXT] public Object deserializeSetAndReturn(JsonParser jp, DeserializationContext ctxt, Object instance) throws IOException, JsonProcessingException { Object id = _valueDeserializer.deserialize(jp, ctxt); <extra_id_0> roid.bindItem(instance); SettableBeanPrope... |
NodeTraversal t = new NodeTraversal(compiler, finder); | [BUG] NodeTraversal t = new NodeTraversal( finder, compiler); [CONTEXT] AbstractCompiler compiler) { AbstractPostOrderCallback finder = new AbstractPostOrderCallback() { @Override public void visit(NodeTraversal t, Node n, Node parent) { if(jsScope == t.getScope() || !NodeUtil.isName(n) || NodeUtil.isFunction(parent)) ... |
rule = selectNumberRule(Calendar.DAY_OF_YEAR, tokenLen); | [BUG] rule = selectNumberRule( Calendar.DAY_OF_YEAR, mField); [CONTEXT] rule = selectNumberRule(Calendar.HOUR_OF_DAY, tokenLen); break; case 'm': // minute in hour(number) rule = selectNumberRule(Calendar.MINUTE, tokenLen); break; case 's': // second in minute(number) rule = selectNumberRule(Calendar.SECOND, tokenLen);... |
!contains(value, index + 1, 2,"CE","CI")) { | [BUG] !contains( value, index + 1, 2,"CE","C")){ [CONTEXT] } else if(contains(value, index, 2,"CI","CE","CY")) { if(contains(value, index, 3,"CIO","CIE","CIA")) { result.append('S', 'X'); } else { result.append('S'); } index += 2; } else { result.append('K'); if(contains(value, index + 1, 2," C"," Q"," G")) { index += ... |
cb.reset(); | [BUG] cb.getLength(); [CONTEXT] public String[] toSourceArray() { return runInCompilerThread(new Callable<String[]>() { public String[] call() throws Exception { Tracer tracer = newTracer("toSourceArray"); try { int numInputs = inputs_.length; String[] sources = new String[numInputs]; CodeBuilder cb = new CodeBuilder()... |
buf.append("ACC_INTERFACE"); | [BUG] None [CONTEXT] } buf.append("ACC_ANNOTATION"); first = false; } if((access & Opcodes.ACC_ABSTRACT) != 0) { if(!first) { buf.append(" +"); } buf.append("ACC_ABSTRACT"); first = false; } if((access & Opcodes.ACC_INTERFACE) != 0) { if(!first) { buf.append(" +"); } <extra_id_0> first = false; } if((access & Opcodes... |
if(module != null && info.moduleToContainDecl != null && module != info.moduleToContainDecl && !moduleGraph.dependsOn(module, info.moduleToContainDecl)) { | [BUG] if(info != null && module.moduleToContainDecl != null && module != info.moduleToContainDecl && !moduleGraph.dependsOn( module, info.moduleToContainDecl)){ [CONTEXT] Node prev = n; for(Node ancestor : n.getAncestors()) { if(ancestor.getType() == Token.SCRIPT) { info.parentForNewVarDecl = ancestor; info.siblingToIn... |
result[0] =(byte)(value & BYTE_MASK); | [BUG] None [CONTEXT] public byte[] getBytes() { byte[] result = new byte[2]; <extra_id_0> result[1] =(byte)((value & BYTE_1_MASK) >> BYTE_1_SHIFT); return result; } [METHOD] getBytes |
_deserializationConfig = _deserializationConfig.with(hi); | [BUG] None [CONTEXT] public Object setHandlerInstantiator(HandlerInstantiator hi) { <extra_id_0> _serializationConfig = _serializationConfig.with(hi); return this; } [METHOD] setHandlerInstantiator |
txt = txt.replaceAll("w$","3"); | [BUG] txt = txt.replaceAll("n+","N");txt = txt.replaceAll("w$","3"); [CONTEXT] txt = txt.replaceAll("^y","A"); // 2.0 only txt = txt.replaceAll("y","3");// 2.0 only txt = txt.replaceAll("3gh3","3kh3"); txt = txt.replaceAll("gh","22"); txt = txt.replaceAll("g","k"); txt = txt.replaceAll("s+","S"); txt = txt.replaceAll("... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.