所以我有一个字符串:
users/9881570/?access_token=
我尝试与正则表达式匹配:
NSRegularExpression * regex = [NSRegularExpression regularExpressionWithPattern:@"users/\\d/?access_token=" options:NSRegularExpressionCaseInsensitive error:&error];
NSArray* wordArray = [regex matchesInString:self.currentRequestURL_
options:0 range:NSMakeRange(0, [self.currentRequestURL_ length])];
但是,wordArray 的计数为 0。为什么这不匹配?