mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-26 02:51:16 -03:00
[clang-tidy] Convert loops to range based
Found with modernize-loop-convert Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
ridiculousfish
parent
1055ff321c
commit
586ac3dfa7
@@ -435,8 +435,7 @@ rgb_color_t best_color(const std::vector<rgb_color_t> &candidates, color_support
|
||||
}
|
||||
|
||||
rgb_color_t first_rgb = rgb_color_t::none(), first_named = rgb_color_t::none();
|
||||
for (size_t i = 0; i < candidates.size(); i++) {
|
||||
const rgb_color_t &color = candidates.at(i);
|
||||
for (const auto &color : candidates) {
|
||||
if (first_rgb.is_none() && color.is_rgb()) {
|
||||
first_rgb = color;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user