Project

General

Profile

Bug #5830

"".byteslice(0) != "".byteslice(0, 0)

Added by brixen (Brian Shirai) almost 8 years ago. Updated almost 8 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Target version:
-
ruby -v:
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-darwin10.8.0]
Backport:
[ruby-core:41860]

History

Updated by naruse (Yui NARUSE) almost 8 years ago

  • Status changed from Open to Rejected

It's spec.

It follows String#slice's behavior; it returns "" for str.slice(str.length, 0).
irb(main):005:0> ["a".slice(1), "a".slice(1, 0)]
=> [nil, ""]

Updated by Anonymous almost 8 years ago

On Dec 31, 2011, at 3:32 AM, Brian Ford wrote:


Bug #5830: "".byteslice(0) !

Also available in: Atom PDF