search: interpret escaped parentheses in heuristic
Created by: rvantonder
DO NOT REVIEW, WIP. Description is for myself.
Stacked on #11128.
This PR changes a function that controls a heuristic when interpreting syntax like ()
as patterns versus expression groups. When this heuristic encounters escaped parentheses, like \(\)
, it will interpret these (including slashes). We want to actually interpret this escape sequence here, since if this heuristic fires, it implies that the string is literal.