regexp-opt-depth
regexp-opt-depth is an autoloaded compiled Lisp function in `regexp-opt.el
'.
(regexp-opt-depth REGEXP)
Return the depth of REGEXP.
This means the number of non-shy regexp grouping constructs
(parenthesized expressions) in REGEXP.