Commit 1b30b28c authored by Sebastian Holtermann's avatar Sebastian Holtermann
Browse files

cmOutputConverter: Let cmOutputConverterIsShellOperator accept cm::string_view

parent 6675f785
...@@ -71,9 +71,9 @@ std::string cmOutputConverter::ConvertDirectorySeparatorsForShell( ...@@ -71,9 +71,9 @@ std::string cmOutputConverter::ConvertDirectorySeparatorsForShell(
return result; return result;
} }
static bool cmOutputConverterIsShellOperator(const std::string& str) static bool cmOutputConverterIsShellOperator(cm::string_view str)
{ {
static std::set<std::string> const shellOperators{ static std::set<cm::string_view> const shellOperators{
"<", ">", "<<", ">>", "|", "||", "&&", "&>", "1>", "2>", "2>&1", "1>&2" "<", ">", "<<", ">>", "|", "||", "&&", "&>", "1>", "2>", "2>&1", "1>&2"
}; };
return (shellOperators.count(str) != 0); return (shellOperators.count(str) != 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment