Terminate loop if generated string longer than the last; ref #3489

parent 63dbed00
......@@ -345,6 +345,7 @@ class String
return self if !excl && str == other_str
str = str.succ
return self if excl && str == other_str
return self if str.size > other_str.size
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment