Swift: extension to NSRegularExpressions to allow an alternative to matchesInString which allows a Range<String.Index> to be used