Err... why is there a new String method for getting the lice of bytes?
'hello'.byteslice(2, 2) # => "ll"
I don't like getting lice ;)
(In other words what happened to good old readable underscores?)
Updated by agrimm (Andrew Grimm) almost 9 years ago
Ruby 1.9.3 has been released with the method spelt byteslice. I suspect it will make this spelling change less likely, as people won't want to use byte_slice in Ruby 2.0 but remember to use byteslice in Ruby 1.9.3 patchlevel 0.
Updated by ayumin (Ayumu AIZAWA) almost 9 years ago
$BF1$8$h$&$JM}M3$GL>A0$,JQ$@!J$H$$$o$l$=$&$J!K%a%=%C%I$K(B bytesize $B$,$"$j$$9$N$G$3$A$i$b(B
byte_size $B$H$$$&(B alias $B$rMQ0U$7$F$O$$$+$,$G$7$g$&$+!#(B