diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2016-05-14 23:34:47 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2016-05-14 23:34:47 -0700 |
commit | 5052a6ff964bd6df935bc8279097c2ff6db1e4cf (patch) | |
tree | 5527f1f6e525ba6fa26d9927ee223bd4ad1fd2be /057shape_shifting_container.cc | |
parent | e5a45387e54db5a4c57aa69c1529b90bb177b1e1 (diff) | |
download | mu-5052a6ff964bd6df935bc8279097c2ff6db1e4cf.tar.gz |
2959
Diffstat (limited to '057shape_shifting_container.cc')
-rw-r--r-- | 057shape_shifting_container.cc | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/057shape_shifting_container.cc b/057shape_shifting_container.cc index 07848600..d1feb0fb 100644 --- a/057shape_shifting_container.cc +++ b/057shape_shifting_container.cc @@ -252,7 +252,16 @@ replace_type_ingredients(element, type, info); :(before "Compute Exclusive Container Size(element)") replace_type_ingredients(element, type, info); :(before "Compute Container Address Offset(element)") -replace_type_ingredients(element, type, info); +replace_type_ingredients(element, curr_type, curr_info); +if (contains_type_ingredient(element)) { + // error raised elsewhere; just clean up and leave + while (!containers.empty()) { + delete containers.top().first; + containers.pop(); + } + return; +} + :(code) void replace_type_ingredients(reagent& element, const type_tree* caller_type, const type_info& info) { if (contains_type_ingredient(element)) { |