Made the GenericParser thread safe.