From 12b51f36dce4bf1148f02e1f3629c25fc45be2f9 Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Fri, 30 Oct 2015 10:10:35 -0700 Subject: 2327 --- 030container.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/030container.cc b/030container.cc index d9497ad4..dd596146 100644 --- a/030container.cc +++ b/030container.cc @@ -401,9 +401,7 @@ void insert_container(const string& command, kind_of_type kind, istream& in) { info.element_names.push_back(slurp_until(inner, ':')); trace(9993, "parse") << " element name: " << info.element_names.back() << end(); type_tree* new_type = NULL; - type_tree** curr_type = &new_type; - vector types; - while (!inner.eof()) { + for (type_tree** curr_type = &new_type; !inner.eof(); curr_type = &(*curr_type)->right) { string type_name = slurp_until(inner, ':'); // End insert_container Special Uses(type_name) if (Type_ordinal.find(type_name) == Type_ordinal.end() @@ -413,7 +411,6 @@ void insert_container(const string& command, kind_of_type kind, istream& in) { } *curr_type = new type_tree(Type_ordinal[type_name]); trace(9993, "parse") << " type: " << Type_ordinal[type_name] << end(); - curr_type = &(*curr_type)->right; } info.elements.push_back(new_type); } -- cgit 1.4.1-2-gfad0