@@ -24,16 +24,16 @@ void ai_baset::output(
2424 const goto_functionst &goto_functions,
2525 std::ostream &out) const
2626{
27- forall_goto_functions (f_it, goto_functions)
27+ for ( const auto &gf_entry : goto_functions. function_map )
2828 {
29- if (f_it-> second .body_available ())
29+ if (gf_entry. second .body_available ())
3030 {
3131 out << " ////\n " ;
32- out << " //// Function: " << f_it-> first << " \n " ;
32+ out << " //// Function: " << gf_entry. first << " \n " ;
3333 out << " ////\n " ;
3434 out << " \n " ;
3535
36- output (ns, f_it-> first , f_it-> second .body , out);
36+ output (ns, gf_entry. first , gf_entry. second .body , out);
3737 }
3838 }
3939}
@@ -64,16 +64,16 @@ jsont ai_baset::output_json(
6464{
6565 json_objectt result;
6666
67- forall_goto_functions (f_it, goto_functions)
67+ for ( const auto &gf_entry : goto_functions. function_map )
6868 {
69- if (f_it-> second .body_available ())
69+ if (gf_entry. second .body_available ())
7070 {
71- result[id2string (f_it-> first )] =
72- output_json (ns, f_it-> first , f_it-> second .body );
71+ result[id2string (gf_entry. first )] =
72+ output_json (ns, gf_entry. first , gf_entry. second .body );
7373 }
7474 else
7575 {
76- result[id2string (f_it-> first )]= json_arrayt ();
76+ result[id2string (gf_entry. first )] = json_arrayt ();
7777 }
7878 }
7979
@@ -111,17 +111,18 @@ xmlt ai_baset::output_xml(
111111{
112112 xmlt program (" program" );
113113
114- forall_goto_functions (f_it, goto_functions)
114+ for ( const auto &gf_entry : goto_functions. function_map )
115115 {
116116 xmlt function (
117117 " function" ,
118- {{" name" , id2string (f_it-> first )},
119- {" body_available" , f_it-> second .body_available () ? " true" : " false" }},
118+ {{" name" , id2string (gf_entry. first )},
119+ {" body_available" , gf_entry. second .body_available () ? " true" : " false" }},
120120 {});
121121
122- if (f_it-> second .body_available ())
122+ if (gf_entry. second .body_available ())
123123 {
124- function.new_element (output_xml (ns, f_it->first , f_it->second .body ));
124+ function.new_element (
125+ output_xml (ns, gf_entry.first , gf_entry.second .body ));
125126 }
126127
127128 program.new_element (function);
@@ -194,8 +195,8 @@ void ai_baset::initialize(const irep_idt &, const goto_programt &goto_program)
194195
195196void ai_baset::initialize (const goto_functionst &goto_functions)
196197{
197- forall_goto_functions (it, goto_functions)
198- initialize (it-> first , it-> second );
198+ for ( const auto &gf_entry : goto_functions. function_map )
199+ initialize (gf_entry. first , gf_entry. second );
199200}
200201
201202void ai_baset::finalize ()
0 commit comments