cprover
natural_loops.cpp
Go to the documentation of this file.
1 /*******************************************************************\
2 
3 Module: Dominators
4 
5 Author: Georg Weissenbacher, georg@weissenbacher.name
6 
7 \*******************************************************************/
8 
11 
12 #include "natural_loops.h"
13 
14 #include <iostream>
15 
16 void show_natural_loops(const goto_functionst &goto_functions)
17 {
18  forall_goto_functions(it, goto_functions)
19  {
20  std::cout << "*** " << it->first << '\n';
21 
22  natural_loopst natural_loops;
23  natural_loops(it->second.body);
24  natural_loops.output(std::cout);
25 
26  std::cout << '\n';
27  }
28 }
void output(std::ostream &) const
Print all natural loops that were found.
void show_natural_loops(const goto_functionst &goto_functions)
Compute natural loops in a goto_function.
#define forall_goto_functions(it, functions)