aboutsummaryrefslogtreecommitdiff
path: root/build2/bin/target.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-02-07 08:09:53 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-02-13 12:42:42 +0200
commit7b9eb752cad04aaadc4552d0f26d307b04af1869 (patch)
treed19cdb450ddec384ec41d9129f8d4afecc14acb7 /build2/bin/target.cxx
parentbe773edfa2c8f8f3230509bbd713542d20fbb37e (diff)
Pass const target& to recipes
Diffstat (limited to 'build2/bin/target.cxx')
-rw-r--r--build2/bin/target.cxx20
1 files changed, 10 insertions, 10 deletions
diff --git a/build2/bin/target.cxx b/build2/bin/target.cxx
index ba15c7d..caef8e0 100644
--- a/build2/bin/target.cxx
+++ b/build2/bin/target.cxx
@@ -22,7 +22,7 @@ namespace build2
obj* o (targets.find<obj> (dir, out, n));
obje* e (new obje (move (dir), move (out), move (n)));
- if ((e->group = o))
+ if ((e->group = o) != nullptr)
o->e = e;
return make_pair (e, move (ext));
@@ -49,7 +49,7 @@ namespace build2
obj* o (targets.find<obj> (dir, out, n));
obja* a (new obja (move (dir), move (out), move (n)));
- if ((a->group = o))
+ if ((a->group = o) != nullptr)
o->a = a;
return make_pair (a, move (ext));
@@ -76,7 +76,7 @@ namespace build2
obj* o (targets.find<obj> (dir, out, n));
objs* s (new objs (move (dir), move (out), move (n)));
- if ((s->group = o))
+ if ((s->group = o) != nullptr)
o->s = s;
return make_pair (s, move (ext));
@@ -106,13 +106,13 @@ namespace build2
obj* o (new obj (move (dir), move (out), move (n)));
- if ((o->e = e))
+ if ((o->e = e) != nullptr)
e->group = o;
- if ((o->a = a))
+ if ((o->a = a)!= nullptr)
a->group = o;
- if ((o->s = s))
+ if ((o->s = s)!= nullptr)
s->group = o;
return make_pair (o, move (ext));
@@ -141,7 +141,7 @@ namespace build2
lib* l (t == liba::static_type ? targets.find<lib> (d, o, n) : nullptr);
liba* a (new liba (move (d), move (o), move (n)));
- if ((a->group = l))
+ if ((a->group = l) != nullptr)
l->a = a;
return make_pair (a, move (ext));
@@ -182,7 +182,7 @@ namespace build2
lib* l (t == libs::static_type ? targets.find<lib> (d, o, n) : nullptr);
libs* s (new libs (move (d), move (o), move (n)));
- if ((s->group = l))
+ if ((s->group = l) != nullptr)
l->s = s;
return make_pair (s, move (ext));
@@ -222,10 +222,10 @@ namespace build2
lib* l (new lib (move (d), move (o), move (n)));
- if ((l->a = a))
+ if ((l->a = a) != nullptr)
a->group = l;
- if ((l->s = s))
+ if ((l->s = s) != nullptr)
s->group = l;
return make_pair (l, move (ext));