mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Remove unnecessary assignment in String#upto
Co-authored-by: taiyoslime <t@iyosli.me> Co-authored-by: smallkirby <ssmallkirby@gmail.com>
This commit is contained in:
@@ -422,7 +422,6 @@ class String
|
||||
# both edges are all digits
|
||||
bi = self.to_i(10)
|
||||
ei = max.to_i(10)
|
||||
len = self.length
|
||||
if (bi > 0 or bi == "0"*len) and (ei > 0 or ei == "0"*maxlen)
|
||||
while bi <= ei
|
||||
break if exclusive and bi == ei
|
||||
|
||||
Reference in New Issue
Block a user