script::dom::htmlinputelement

Function check_js_regex_syntax

Source
fn check_js_regex_syntax(cx: JSContext, pattern: &str) -> bool
Expand description

Check if the pattern by itself is valid first, and not that it only becomes valid once we add ^(?: and )$.