diff --git a/deps/v8/src/builtins/builtins-string-gen.cc b/deps/v8/src/builtins/builtins-string-gen.cc index 25bf14ce2bd83d..ed559eadfdf911 100644 --- a/deps/v8/src/builtins/builtins-string-gen.cc +++ b/deps/v8/src/builtins/builtins-string-gen.cc @@ -1190,14 +1190,11 @@ TF_BUILTIN(StringPrototypeSplit, StringBuiltinsAssembler) { }); // String and integer conversions. - // TODO(jgruber): The old implementation used Uint32Max instead of SmiMax - - // but AFAIK there should not be a difference since arrays are capped at Smi - // lengths. Callable tostring_callable = CodeFactory::ToString(isolate()); Node* const subject_string = CallStub(tostring_callable, context, receiver); Node* const limit_number = - Select(IsUndefined(limit), [=]() { return SmiConstant(Smi::kMaxValue); }, + Select(IsUndefined(limit), [=]() { return NumberConstant(kMaxUInt32); }, [=]() { return ToUint32(context, limit); }, MachineRepresentation::kTagged); Node* const separator_string =