Expose regexp in API.