diff options
author | Alex Auvolat <alex.auvolat@ansys.com> | 2014-06-17 17:38:29 +0200 |
---|---|---|
committer | Alex Auvolat <alex.auvolat@ansys.com> | 2014-06-17 17:38:29 +0200 |
commit | 2b62d844cc81b60bcbdfc145097139995ea6f3a0 (patch) | |
tree | 8c34ecf12daf28569ac8a5364eb0438b9262308c /interpret/ast_util.ml | |
parent | ce4f339ced19e2ff7d79c2c8ec5b3ee478d5d365 (diff) | |
download | scade-analyzer-2b62d844cc81b60bcbdfc145097139995ea6f3a0.tar.gz scade-analyzer-2b62d844cc81b60bcbdfc145097139995ea6f3a0.zip |
Some abstract interpretation does something now.
Diffstat (limited to 'interpret/ast_util.ml')
-rw-r--r-- | interpret/ast_util.ml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/interpret/ast_util.ml b/interpret/ast_util.ml index f5a1978..9cfe995 100644 --- a/interpret/ast_util.ml +++ b/interpret/ast_util.ml @@ -41,7 +41,7 @@ let get_root_scope p root = (* Utility : find instances declared in an expression *) (* extract_instances : - prog -> expr ext -> (id * eqs * (var_def * expr ext) list) list + prog -> expr ext -> (id * id * eqs * (var_def * expr ext) list) list *) let rec extract_instances p e = match fst e with | AST_idconst _ | AST_identifier _ @@ -56,7 +56,7 @@ let rec extract_instances p e = match fst e with let more = List.flatten (List.map (extract_instances p) args) in let (node, _) = find_node_decl p f in let args_x = List.map2 (fun id arg -> id, arg) node.args args in - (id, node.body, args_x)::more + (f, id, node.body, args_x)::more (* Utility : find pre declarations in an expression *) |