From 171b0e3a3b6f5bde0489c0e12c679fcefdeca54f Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 2 Sep 2021 11:31:25 +0200 Subject: Don't consider aliasing in variable override lookup --- libbuild2/scope.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'libbuild2/scope.cxx') diff --git a/libbuild2/scope.cxx b/libbuild2/scope.cxx index ad01aa7..39aba8f 100644 --- a/libbuild2/scope.cxx +++ b/libbuild2/scope.cxx @@ -319,8 +319,12 @@ namespace build2 return lookup_type (); // Note: using the original as storage variable. + // Note: have to suppress aliases since used for something else. // - return lookup_type (s->vars.lookup (*o).first, &var, &s->vars); + return lookup_type ( + s->vars.lookup (*o, true /* typed */, false /* aliased */).first, + &var, + &s->vars); }; // Return true if a value is from this scope (either target type/pattern- -- cgit v1.1