From 53f02bf28dae507a51515ed6ac03226d68816494 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 2 Feb 2017 10:20:50 +0200 Subject: Store extension in target map key rather than in target This is in preparation for locking its modification/access. --- build2/scope.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'build2/scope.cxx') diff --git a/build2/scope.cxx b/build2/scope.cxx index 0c80052..0b76647 100644 --- a/build2/scope.cxx +++ b/build2/scope.cxx @@ -621,7 +621,7 @@ namespace build2 return r; } - static target* + static pair> derived_tt_factory (const target_type& t, dir_path d, dir_path o, @@ -639,8 +639,8 @@ namespace build2 const target_type* bt (t.base); for (; bt->factory == &derived_tt_factory; bt = bt->base) ; - target* r (bt->factory (t, move (d), move (o), move (n), move (e))); - r->derived_type = &t; + auto r (bt->factory (t, move (d), move (o), move (n), move (e))); + r.first->derived_type = &t; return r; } -- cgit v1.1