[swift-users] What are these types with regular expressions?

晓敏 褚 mirrorinf at icloud.com
Sat Aug 6 07:25:15 CDT 2016

I’m writing a program with regular expressions, and I’m finding it extremely hard to code with these in swift. I got a [TextCheckingResult] from the matching function, and there is no document on what TextCheckingResult is and how could I work with it. And when I try to use range to get a substring, I got a Range<Int>, but the substring:with: method requies a Range<Index>. But there is no way I could find any information about the type(or protocol?) Index, and passing a Int fails.
What are they, and how can I work with them?

More information about the swift-users mailing list