mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-07-03 01:41:15 -03:00
[clang-tidy] remove redundant string initialization
Found with readability-redundant-string-init Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
Fabian Homborg
parent
473a5250ae
commit
68467eeca7
@@ -485,7 +485,7 @@ end_execution_reason_t parse_execution_context_t::run_switch_statement(
|
||||
|
||||
// If we expanded to nothing, match the empty string.
|
||||
assert(switch_values_expanded.size() <= 1 && "Should have at most one expansion");
|
||||
wcstring switch_value_expanded = L"";
|
||||
wcstring switch_value_expanded;
|
||||
if (!switch_values_expanded.empty()) {
|
||||
switch_value_expanded = std::move(switch_values_expanded.front().completion);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user