I\'m using a regular expression in a parser, however, it seems to give one result to much, this is my code: Regex:
self.seatSelectRegex = [NSRegularExpressio
This is because your using the NSMatchingReportCompletion
option with enumerateMatchesInString:options:range:usingBlock:
. From Apples documentation:
If the NSMatchingReportCompletion matching option is specified, the Block object will be called once after matching is complete, with nil result and the NSMatchingCompleted matching flag is set in the flags passed to the Block, plus any additional relevant “NSMatchingFlags” from among NSMatchingHitEnd, NSMatchingRequiredEnd, or NSMatchingInternalError.
And the reason your seeing the last block call as a range with location and length set as 0 is because your sending messages to nil
which will return nil
(which is the integer 0).