Cannot invoke initializer for type 'Range<_>' with an argument list of type '(Range<String.Index>)'
dabanlee opened this issue · 3 comments
dabanlee commented
dan085 commented
you can change this line
return String(self[NSRange(start ..< end)])
for this:
let range: Range<Index> = start..<end
return String(self[range])
Regards!!!
yarodevuci commented
@dverdugo85 Thanks!
Dev should update his code and example code
asar1 commented
you can change this line
return String(self[NSRange(start ..< end)])
for this:
let range: Range<Index> = start..<end return String(self[range])
Regards!!!
After updating this,
i've got this error:
Type 'String.Index' does not conform to protocol 'FixedWidthInteger'