CTrans_utils.Loops
Module that provides utility functions for translating different types of loops.
type loop_kind =
| For of {
init : ATDGenerated.Clang_ast_t.stmt;
decl_stmt : ATDGenerated.Clang_ast_t.stmt;
condition : ATDGenerated.Clang_ast_t.stmt;
increment : ATDGenerated.Clang_ast_t.stmt;
body : ATDGenerated.Clang_ast_t.stmt;
}
| While of {
decl_stmt : ATDGenerated.Clang_ast_t.stmt option;
condition : ATDGenerated.Clang_ast_t.stmt;
body : ATDGenerated.Clang_ast_t.stmt;
}
| DoWhile of {
condition : ATDGenerated.Clang_ast_t.stmt;
body : ATDGenerated.Clang_ast_t.stmt;
}
val get_cond : loop_kind -> ATDGenerated.Clang_ast_t.stmt
val get_body : loop_kind -> ATDGenerated.Clang_ast_t.stmt