[quickjs-devel] Re: A possible issue about the abstract operation ToNumber

  • From: Fabrice Bellard <fabrice@xxxxxxxxxxx>
  • To: quickjs-devel@xxxxxxxxxxxxx
  • Date: Sat, 9 Nov 2019 12:32:31 +0100

Hi,

Thank you for the bug report. It will be fixed in the next release.

Best regards,

Fabrice.

On 11/2/19 2:36 AM, Houyou Yao wrote:

Hi,
    If I understand the ES standard correctly, I think the abstract
operation ToNumber of QuickJS does not meet the ES standard.The details
are as follows:

# Version: quickjs-2019-10-27

# Testcase:
var NISLFuzzingFunc = function() {
    var tmp = Number("-");
    print(tmp);
};
NISLFuzzingFunc();

# Output:
0

# Expected output:
NaN

# Reference of ECMAScript-262:
https://tc39.es/ecma262/#sec-tonumber<https://tc39.es/ecma262/#sec-tonumber>


Best Regards,
Houyou Yao


Other related posts: