aboutsummaryrefslogtreecommitdiff
path: root/build2/target.ixx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2016-07-29 12:40:15 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2016-07-29 12:40:15 +0200
commitb3f6553294bf6455f6fbee542f6481436f62a460 (patch)
treeebedb18342f1bd946b9a62aadcc6eccc076d9ff6 /build2/target.ixx
parent32e2ccb82db1962c659c2dc53e39a74e1f8d3b97 (diff)
Fix bug in prerequisite iteration leave group support
Diffstat (limited to 'build2/target.ixx')
-rw-r--r--build2/target.ixx4
1 files changed, 3 insertions, 1 deletions
diff --git a/build2/target.ixx b/build2/target.ixx
index 5cf5ca9..b9dfa48 100644
--- a/build2/target.ixx
+++ b/build2/target.ixx
@@ -57,7 +57,8 @@ namespace build2
if (k_ == nullptr && g_.count != 0) // Iterating over a normal group.
{
- if (++j_ > g_.count)
+ if (g_.members == nullptr || // leave_group()
+ ++j_ > g_.count)
g_.count = 0;
}
@@ -133,6 +134,7 @@ namespace build2
//
j_ = 0;
g_.count = 1;
+ g_.members = nullptr; // Ugly "special case signal" for operator++.
}
}
}