Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
When the haystack string contained a non-single-byte character, code would previously call `StringSupport.nth` for every backwards step. `nth` walks all the way through the string from the beginning. The combination of these caused O(n^2) behavior. Now `rindex` follows MRI's pattern of simply walking backward until we find the previous character. Fixes #1140