diff options
author | Kartik Agaram <vc@akkartik.com> | 2018-06-25 13:36:27 -0700 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2018-06-25 13:36:27 -0700 |
commit | 2caaa7f18f391995feae550c59fa175af86b6817 (patch) | |
tree | ffe03071ec5be2033c904e1a4e55d6973c5c8d2b /045closure_name.cc | |
parent | b0631dec20089bb142be2ccf28438ebe09489ce5 (diff) | |
download | mu-2caaa7f18f391995feae550c59fa175af86b6817.tar.gz |
4272 - type-check variables in non-local spaces
So far we only checked if a single recipe used a variable with multiple types in any single space. Now we also ensure that the types deduced for a variable in a space are identical across recipes.
Diffstat (limited to '045closure_name.cc')
-rw-r--r-- | 045closure_name.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/045closure_name.cc b/045closure_name.cc index d1c4859a..9fbda150 100644 --- a/045closure_name.cc +++ b/045closure_name.cc @@ -33,9 +33,11 @@ def increment-counter [ //: surrounding space of each recipe. :(before "End Globals") -map<recipe_ordinal, recipe_ordinal> Surrounding_space; +map<recipe_ordinal, recipe_ordinal> Surrounding_space; // internal to transform; no need to snapshot +:(before "End Reset") +Surrounding_space.clear(); -:(before "Transform.push_back(transform_names)") +:(before "Begin Type Modifying Transforms") Transform.push_back(collect_surrounding_spaces); // idempotent :(code) |