diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2022-09-09 14:14:52 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2022-09-09 14:14:52 +0200 |
commit | d7acc2a73594eed81ec8b3227b90a0f18944eedf (patch) | |
tree | 738bdb26aad88304f9459c8f93762c63fc214de2 /libbuild2/parser.hxx | |
parent | 87201b1c10769606214e27e64e88af5b835cb56f (diff) |
Evaluate target specific variable assignment/block on ad hoc members
This is in preparation for (again) not treating primary member of an
ad hoc group as a group for variable lookup.
Diffstat (limited to 'libbuild2/parser.hxx')
-rw-r--r-- | libbuild2/parser.hxx | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/libbuild2/parser.hxx b/libbuild2/parser.hxx index 5f762f7..c59b90e 100644 --- a/libbuild2/parser.hxx +++ b/libbuild2/parser.hxx @@ -190,10 +190,12 @@ namespace build2 using adhoc_names = small_vector<adhoc_names_loc, 1>; - void + vector<reference_wrapper<target>> enter_adhoc_members (adhoc_names_loc&&, bool); - small_vector<reference_wrapper<target>, 1> + small_vector<pair<reference_wrapper<target>, // Target. + vector<reference_wrapper<target>>>, // Ad hoc members. + 1> enter_targets (names&&, const location&, adhoc_names&&, size_t, @@ -772,6 +774,16 @@ namespace build2 } void + replay_skip () + { + assert (replay_ == replay::play); + + assert (!peeked_); + + replay_i_ = replay_data_.size () - 1; + } + + void replay_stop (bool verify = true) { if (verify) |