I'm getting an error when translating some Objective-C code to Swift.
I'm using - attribute:atIndex:effectiveRange: of NSAttributedString and having an error concerning the effectiveRange parameter, which is an NSRangePointer.
Objective-C:
NSRange range;
id value = [self.textanalyze
attribute:attribute
atIndex:index
effectiveRange:&range]
Swift:
var range : NSRange?
var value : Any = self.textanalyze.attribute(attributes,
atIndex: index,
effectiveRange: &range)
I got an error near &range.