зеркало из https://github.com/mozilla/rhino.git
Make interpreted mode consistently return integers too
This commit is contained in:
Родитель
8b7b580cb3
Коммит
c743a3fd0d
|
@ -2150,13 +2150,11 @@ public final class Interpreter extends Icode implements Evaluator {
|
||||||
}
|
}
|
||||||
case Icode_ZERO:
|
case Icode_ZERO:
|
||||||
++stackTop;
|
++stackTop;
|
||||||
stack[stackTop] = DBL_MRK;
|
stack[stackTop] = Integer.valueOf(0);
|
||||||
sDbl[stackTop] = 0;
|
|
||||||
continue Loop;
|
continue Loop;
|
||||||
case Icode_ONE:
|
case Icode_ONE:
|
||||||
++stackTop;
|
++stackTop;
|
||||||
stack[stackTop] = DBL_MRK;
|
stack[stackTop] = Integer.valueOf(1);
|
||||||
sDbl[stackTop] = 1;
|
|
||||||
continue Loop;
|
continue Loop;
|
||||||
case Token.NULL:
|
case Token.NULL:
|
||||||
stack[++stackTop] = null;
|
stack[++stackTop] = null;
|
||||||
|
|
|
@ -16,7 +16,7 @@ public class NumericSeparatorTest {
|
||||||
/** Special Tokenizer test for numeric constant at end. */
|
/** Special Tokenizer test for numeric constant at end. */
|
||||||
@Test
|
@Test
|
||||||
public void numericAtEndOneDigit() {
|
public void numericAtEndOneDigit() {
|
||||||
Utils.assertWithAllOptimizationLevelsES6(1.0, "1");
|
Utils.assertWithAllOptimizationLevelsES6(1, "1");
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Special Tokenizer test for numeric constant at end. */
|
/** Special Tokenizer test for numeric constant at end. */
|
||||||
|
|
|
@ -6187,7 +6187,6 @@ language/expressions/object 867/1169 (74.17%)
|
||||||
accessor-name-literal-numeric-exponent.js {strict: [-1], non-strict: [-1]}
|
accessor-name-literal-numeric-exponent.js {strict: [-1], non-strict: [-1]}
|
||||||
accessor-name-literal-numeric-hex.js {strict: [-1], non-strict: [-1]}
|
accessor-name-literal-numeric-hex.js {strict: [-1], non-strict: [-1]}
|
||||||
accessor-name-literal-numeric-octal.js {strict: [-1], non-strict: [-1]}
|
accessor-name-literal-numeric-octal.js {strict: [-1], non-strict: [-1]}
|
||||||
accessor-name-literal-numeric-zero.js
|
|
||||||
computed-__proto__.js
|
computed-__proto__.js
|
||||||
concise-generator.js
|
concise-generator.js
|
||||||
cpn-obj-lit-computed-property-name-from-assignment-expression-coalesce.js
|
cpn-obj-lit-computed-property-name-from-assignment-expression-coalesce.js
|
||||||
|
|
Загрузка…
Ссылка в новой задаче