From 642d2f1d3f83e3f5e303cf75b9a9d0a563e4ada4 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 15 Apr 2022 10:41:40 +0200 Subject: Omit unnecessary clearing of cached base_scope values --- libbuild2/context.hxx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'libbuild2/context.hxx') diff --git a/libbuild2/context.hxx b/libbuild2/context.hxx index 5cc2115..9083556 100644 --- a/libbuild2/context.hxx +++ b/libbuild2/context.hxx @@ -248,7 +248,12 @@ namespace build2 // "islands" are identified by the load_generation number (0 for the // initial/serial load). It is incremented in case of a phase switch and // can be stored in various "nodes" to verify modifications are only done - // "within the islands". + // "within the islands". Another example of invalidation would be + // insertion of a new scope "under" an existing target thus changing its + // scope hierarchy (and potentially even its base scope). This would be + // bad because we may have made decisions based on the original hierarchy, + // for example, we may have queried a variable which in the new hierarchy + // would "see" a new value from the newly inserted scope. // run_phase phase = run_phase::load; size_t load_generation = 0; -- cgit v1.1