aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/file.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'libbuild2/file.cxx')
-rw-r--r--libbuild2/file.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/libbuild2/file.cxx b/libbuild2/file.cxx
index 396b0fe..5d1487f 100644
--- a/libbuild2/file.cxx
+++ b/libbuild2/file.cxx
@@ -2549,6 +2549,11 @@ namespace build2
context& ctx (base.ctx);
assert (ctx.phase == run_phase::load);
+ // Validate the name.
+ //
+ if (tgt.qualified () && tgt.empty ())
+ fail (loc) << "project-qualified empty name " << tgt;
+
// If metadata is requested, delegate to import_direct() which will lookup
// the target and verify the metadata was loaded.
//