code: public static Pattern regex(String s) {
      return regex(java.util.regex.Pattern.compile(s));
    }
docs: Adapts a regular expression pattern string to a {@link Pattern}.
  
  <p><em>WARNING</em>: in addition to regular expression cost, the returned {@code Pattern} object needs
  to make a substring copy every time it's evaluated. This can incur excessive copying and memory overhead
  when parsing large strings. Consider implementing {@code Pattern} manually for large input.