LibRegex: Avoid use-after-move of trivial object

This is not an actual problem as the object is just an enum, but clion
was bugging me.
This commit is contained in:
Ali Mohammad Pur 2025-01-15 15:21:18 +01:00 committed by Andreas Kling
parent 5876417357
commit 7ceeb85ba7
Notes: github-actions[bot] 2025-01-17 09:35:24 +00:00

View file

@ -80,7 +80,7 @@ Regex<Parser>::Regex(regex::Parser::Result parse_result, ByteString pattern, typ
{
run_optimization_passes();
if (parser_result.error == regex::Error::NoError)
matcher = make<Matcher<Parser>>(this, regex_options | static_cast<decltype(regex_options.value())>(parse_result.options.value()));
matcher = make<Matcher<Parser>>(this, regex_options | static_cast<decltype(regex_options.value())>(parser_result.options.value()));
}
template<class Parser>