Thread safe initialization of NSRegularExpression

My earlier PR for caching the `NSRegularExpression` (#4) wasn't thread safe. Now it is, using `dispatch_once`.