aboutsummaryrefslogtreecommitdiff
path: root/build/algorithm.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2015-06-30 15:07:03 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2015-06-30 15:07:03 +0200
commit70af0087d8efb3f2f7dc9ffdf2568419913f16da (patch)
treedceeab7a3c600add8bf3f3375a2d83ca11213624 /build/algorithm.cxx
parent18568ff0ff3dce89d694b494c5dfc9a32e63c9e6 (diff)
Group "see through" iteration, take 1
Diffstat (limited to 'build/algorithm.cxx')
-rw-r--r--build/algorithm.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/build/algorithm.cxx b/build/algorithm.cxx
index 4f30944..5c7805f 100644
--- a/build/algorithm.cxx
+++ b/build/algorithm.cxx
@@ -34,10 +34,10 @@ namespace build
return create_new_target (pk);
}
- pair<const rule*, void*>
+ pair<const rule*, match_result>
match_impl (action a, target& t, bool apply)
{
- pair<const rule*, void*> r (nullptr, nullptr);
+ pair<const rule*, match_result> r (nullptr, nullptr);
// Clear the resolved targets list before calling match(). The rule
// is free to, say, resize() this list in match() (provided that it
@@ -79,7 +79,7 @@ namespace build
const string& n (i->first);
const rule& ru (i->second);
- void* m (nullptr);
+ match_result m;
{
auto g (
make_exception_guard (
@@ -93,7 +93,7 @@ namespace build
m = ru.match (a, t, hint);
}
- if (m != nullptr)
+ if (m)
{
// Do the ambiguity test.
//
@@ -106,7 +106,7 @@ namespace build
const string& n1 (i->first);
const rule& ru1 (i->second);
- void* m1;
+ match_result m1;
{
auto g (
make_exception_guard (
@@ -120,7 +120,7 @@ namespace build
m1 = ru1.match (a, t, hint);
}
- if (m1 != nullptr)
+ if (m1)
{
if (!ambig)
{