aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/target.txx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2020-08-10 13:40:27 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2020-08-10 13:40:27 +0200
commit9d8ba565d1fd454369506a525997fceb5adae349 (patch)
treeda10d155660ff59cfd82ee7bb45d4503e26c198d /libbuild2/target.txx
parent600da2b97e937b9c96791c291cb5e08cd8526bdd (diff)
Allow holes in group_view array
Diffstat (limited to 'libbuild2/target.txx')
-rw-r--r--libbuild2/target.txx10
1 files changed, 6 insertions, 4 deletions
diff --git a/libbuild2/target.txx b/libbuild2/target.txx
index 777653a..d304daa 100644
--- a/libbuild2/target.txx
+++ b/libbuild2/target.txx
@@ -28,11 +28,13 @@ namespace build2
return;
}
- if (g_.count != 0) // Skip empty see through groups.
- {
- j_ = 1; // Start from the first group member.
+ // Skip empty see through groups.
+ //
+ for (j_ = 1; j_ <= g_.count && g_.members[j_ - 1] == nullptr; ++j_) ;
+ if (j_ <= g_.count)
break;
- }
+
+ g_.count = 0;
}
while (++i_ != r_->e_ && i_->type.see_through);
}