Commit | Line | Data |
---|---|---|
951c7801 C |
1 | type cocci_predicate = Lib_engine.predicate * Ast_cocci.meta_name Ast_ctl.modif |
2 | type formula = | |
3 | (cocci_predicate,Ast_cocci.meta_name, Wrapper_ctl.info) Ast_ctl.generic_ctl | |
4 | ||
5 | let poplz (name,_,ast) = | |
6 | match ast with | |
7 | [ast] -> | |
8 | let ast = Asttopopl.top ast in | |
9 | let ba = Insert_befaft.insert_befaft ast in | |
10 | let qt = Insert_quantifiers.insert_quantifiers ba in | |
11 | [Popltoctl.toctl qt] | |
12 | | _ -> failwith "only one rule allowed" | |
13 | ||
14 | let popl r = | |
15 | match r with | |
16 | Ast_cocci.CocciRule (a,b,c) -> poplz (a,b,c) | |
17 | | _ -> [] |