Status: Available
Owner: ----
Labels: Type-Bug Priority-Low Harmony

New issue 4362 by [email protected]: Minor: String.prototype.repeat supports ''.repeat(any integer)
https://code.google.com/p/v8/issues/detail?id=4362

In the spec, the only range checks for the count argument for repeat are <0 and +Infinity.

http://www.ecma-international.org/ecma-262/6.0/#sec-string.prototype.repeat

This means we should be able to do this:

d8> ''.repeat(%_MaxSmi() + 1)
(d8):1: RangeError: Invalid count value
''.repeat(%_MaxSmi() + 1)
   ^
RangeError: Invalid count value
    at String.repeat (native)
    at (d8):1:4

This seems to be related to the failure of built-ins/String/prototype/repeat/empty-string-returns-empty from test262.

--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to