src: update outdated references to spec sections
The exact section has changed in recent versions of ECMA-262, so fix the section number and explicitly mark the edition of the standard to avoid having to update it in the future. PR-URL: https://github.com/nodejs/node/pull/53832 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
This commit is contained in:
parent
953abf4887
commit
3a43e55a00
@ -501,7 +501,7 @@ void ArrayBufferViewContents<T, S>::ReadValue(v8::Local<v8::Value> buf) {
|
||||
}
|
||||
}
|
||||
|
||||
// ECMA262 20.1.2.5
|
||||
// ECMA-262, 15th edition, 21.1.2.5. Number.isSafeInteger
|
||||
inline bool IsSafeJsInt(v8::Local<v8::Value> v) {
|
||||
if (!v->IsNumber()) return false;
|
||||
double v_d = v.As<v8::Number>()->Value();
|
||||
|
@ -215,7 +215,7 @@ void DumpJavaScriptBacktrace(FILE* fp);
|
||||
#define UNREACHABLE(...) \
|
||||
ERROR_AND_ABORT("Unreachable code reached" __VA_OPT__(": ") __VA_ARGS__)
|
||||
|
||||
// ECMA262 20.1.2.6 Number.MAX_SAFE_INTEGER (2^53-1)
|
||||
// ECMA-262, 15th edition, 21.1.2.6. Number.MAX_SAFE_INTEGER (2^53-1)
|
||||
constexpr int64_t kMaxSafeJsInteger = 9007199254740991;
|
||||
|
||||
inline bool IsSafeJsInt(v8::Local<v8::Value> v);
|
||||
|
Loading…
x
Reference in New Issue
Block a user