diff options
Diffstat (limited to 'build/target.cxx')
-rw-r--r-- | build/target.cxx | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/build/target.cxx b/build/target.cxx index b4c4481..4168991 100644 --- a/build/target.cxx +++ b/build/target.cxx @@ -159,10 +159,12 @@ namespace build // since it will do nothing and it most likely not what the author // intended. // - if (target* t = search_existing_target (p)) - return t; + target* t (search_existing_target (p)); + + if (t == nullptr) + fail << "no explicit target for prerequisite " << p; - fail << "no explicit target for prerequisite " << p; + return t; } // type info |