From 59954eef4d7a6044115a8d749d36fa16f840ea6a Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 1 Aug 2017 13:02:09 +0200 Subject: Fix bug in ad hoc member traversal --- build2/algorithm.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'build2') diff --git a/build2/algorithm.cxx b/build2/algorithm.cxx index 2ce34e3..174c395 100644 --- a/build2/algorithm.cxx +++ b/build2/algorithm.cxx @@ -263,7 +263,7 @@ namespace build2 } const_ptr* mp (&t.member); - for (auto p (*mp); p != nullptr && !p->is_a (tt); mp = &p->member) ; + for (; *mp != nullptr && !(*mp)->is_a (tt); mp = &(*mp)->member) ; const target& m (*mp != nullptr // Might already be there. ? **mp -- cgit v1.1