From 5164c843513212ab1ac1f721c4de04b6a865eb0c Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 19 Jan 2017 16:50:40 +0200 Subject: Get rid of extension_pool --- build2/bin/rule.cxx | 4 ++-- build2/bin/target.cxx | 28 ++++++++++++++-------------- 2 files changed, 16 insertions(+), 16 deletions(-) (limited to 'build2/bin') diff --git a/build2/bin/rule.cxx b/build2/bin/rule.cxx index 70ad7df..ede2c85 100644 --- a/build2/bin/rule.cxx +++ b/build2/bin/rule.cxx @@ -75,7 +75,7 @@ namespace build2 if (a) { if (t.a == nullptr) - t.a = &search (t.dir, t.out, t.name, nullptr, nullptr); + t.a = &search (t.dir, t.out, t.name, nullopt, nullptr); match_only (act, *t.a); } @@ -83,7 +83,7 @@ namespace build2 if (s) { if (t.s == nullptr) - t.s = &search (t.dir, t.out, t.name, nullptr, nullptr); + t.s = &search (t.dir, t.out, t.name, nullopt, nullptr); match_only (act, *t.s); } diff --git a/build2/bin/target.cxx b/build2/bin/target.cxx index 9086369..e9ef81e 100644 --- a/build2/bin/target.cxx +++ b/build2/bin/target.cxx @@ -17,10 +17,10 @@ namespace build2 dir_path dir, dir_path out, string n, - const string* ext) + optional ext) { obj* o (targets.find (dir, out, n)); - obje* e (new obje (move (dir), move (out), move (n), ext)); + obje* e (new obje (move (dir), move (out), move (n), move (ext))); if ((e->group = o)) o->e = e; @@ -44,10 +44,10 @@ namespace build2 dir_path dir, dir_path out, string n, - const string* ext) + optional ext) { obj* o (targets.find (dir, out, n)); - obja* a (new obja (move (dir), move (out), move (n), ext)); + obja* a (new obja (move (dir), move (out), move (n), move (ext))); if ((a->group = o)) o->a = a; @@ -71,10 +71,10 @@ namespace build2 dir_path dir, dir_path out, string n, - const string* ext) + optional ext) { obj* o (targets.find (dir, out, n)); - objs* s (new objs (move (dir), move (out), move (n), ext)); + objs* s (new objs (move (dir), move (out), move (n), move (ext))); if ((s->group = o)) o->s = s; @@ -98,13 +98,13 @@ namespace build2 dir_path dir, dir_path out, string n, - const string* ext) + optional ext) { obje* e (targets.find (dir, out, n)); obja* a (targets.find (dir, out, n)); objs* s (targets.find (dir, out, n)); - obj* o (new obj (move (dir), move (out), move (n), ext)); + obj* o (new obj (move (dir), move (out), move (n), move (ext))); if ((o->e = e)) e->group = o; @@ -134,12 +134,12 @@ namespace build2 dir_path d, dir_path o, string n, - const string* ext) + optional ext) { // Only link-up to the group if the types match exactly. // lib* l (t == liba::static_type ? targets.find (d, o, n) : nullptr); - liba* a (new liba (move (d), move (o), move (n), ext)); + liba* a (new liba (move (d), move (o), move (n), move (ext))); if ((a->group = l)) l->a = a; @@ -175,12 +175,12 @@ namespace build2 dir_path d, dir_path o, string n, - const string* ext) + optional ext) { // Only link-up to the group if the types match exactly. // lib* l (t == libs::static_type ? targets.find (d, o, n) : nullptr); - libs* s (new libs (move (d), move (o), move (n), ext)); + libs* s (new libs (move (d), move (o), move (n), move (ext))); if ((s->group = l)) l->s = s; @@ -215,12 +215,12 @@ namespace build2 dir_path d, dir_path o, string n, - const string* ext) + optional ext) { liba* a (targets.find (d, o, n)); libs* s (targets.find (d, o, n)); - lib* l (new lib (move (d), move (o), move (n), ext)); + lib* l (new lib (move (d), move (o), move (n), move (ext))); if ((l->a = a)) a->group = l; -- cgit v1.1