Don't operate on a collection and a range of indices if you can help it.
dabrahams opened this issue · comments
I just noticed https://developer.apple.com/documentation/swift/customconsumingregexcomponent/consuming(_:startingat:in:)
In general APIs are cleaner if you just operate on collections and use slices to limit what you're looking at. Obviously if that's not possible in this case, please ignore. Otherwise, please apply as broadly as possible ;-)