string-numeric-separator-literal-dd-dot-dd-ep-sign-plus-dd-nsl-dd.js (735B)
1 // Copyright (C) 2017 the V8 project authors. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 4 /*--- 5 esid: prod-NumericLiteralSeparator 6 description: NumericLiteralSeparator is not valid on string conversions for ToNumber operations 7 info: | 8 DecimalDigits `.` DecimalDigits ExponentPart_opt `+` DecimalDigits 9 10 NumericLiteralSeparator :: 11 _ 12 13 DecimalLiteral :: 14 DecimalIntegerLiteral . DecimalDigits_opt ExponentPart_opt 15 16 DecimalDigits :: 17 ... 18 DecimalDigits NumericLiteralSeparator DecimalDigit 19 20 SignedInteger :: 21 ... 22 + DecimalDigits 23 ... 24 25 features: [numeric-separator-literal] 26 ---*/ 27 28 assert.sameValue(Number("1.0e+1_0"), NaN, "1.0e+1_0"); 29 30 reportCompare(0, 0);