I believe this is a safe modification because the regexes are equivalent. The difference amounts to adding (?: ... ) which inserts a non matching group. I verified (by hand) that in chrome v8 inserting a non matching group inside a matching group does not affect the matching group. The outer group still matches.
I believe this is a safe modification because the regexes are equivalent. The difference amounts to adding
(?: ... )
which inserts a non matching group. I verified (by hand) that in chrome v8 inserting a non matching group inside a matching group does not affect the matching group. The outer group still matches.