1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 08:58:11 +00:00

LibJS: Rename Value::{is_integer => is_integral_number}

The implementation matches the specification, so lets match the name
as well. :^)
This commit is contained in:
Idan Horowitz 2021-06-16 13:17:06 +03:00 committed by Linus Groh
parent 07992c8da6
commit 9127d83927
8 changed files with 12 additions and 12 deletions

View file

@ -52,7 +52,7 @@ Value ArrayConstructor::call()
if (vm().argument_count() == 1 && vm().argument(0).is_number()) {
auto array_length_value = vm().argument(0);
if (!array_length_value.is_integer() || array_length_value.as_i32() < 0) {
if (!array_length_value.is_integral_number() || array_length_value.as_i32() < 0) {
vm().throw_exception<RangeError>(global_object(), ErrorType::InvalidLength, "array");
return {};
}