diff options
author | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-01-07 15:07:22 +0100 |
---|---|---|
committer | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-01-07 15:07:22 +0100 |
commit | d9f8744ea219fb04057059cdcbf7162534c63852 (patch) | |
tree | 9c1c2d0fa9011bd656d1eae7bbee6db954b3adfe /cpu/netlist_gen.ml | |
parent | c8a30baeb18756f2cc246de6a575943fcf9b7ed4 (diff) | |
download | SystDigit-Projet-d9f8744ea219fb04057059cdcbf7162534c63852.tar.gz SystDigit-Projet-d9f8744ea219fb04057059cdcbf7162534c63852.zip |
Document.
Diffstat (limited to 'cpu/netlist_gen.ml')
-rw-r--r-- | cpu/netlist_gen.ml | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/cpu/netlist_gen.ml b/cpu/netlist_gen.ml index 1aad452..016c595 100644 --- a/cpu/netlist_gen.ml +++ b/cpu/netlist_gen.ml @@ -16,9 +16,8 @@ let add p id eq size = assert (not (Env.mem id p.p_vars) || (Env.find id p.p_vars = size)); assert (not (List.mem_assoc id p.p_eqs)); - { p_eqs = (id, eq)::p.p_eqs; - p_inputs = p.p_inputs; - p_outputs = p.p_outputs; + { p with + p_eqs = (id, eq)::p.p_eqs; p_vars = Env.add id size p.p_vars } let get id = @@ -195,9 +194,7 @@ let program entries outputs = p, outputs) (p, []) outputs in - { p_inputs = p.p_inputs; - p_eqs = p.p_eqs; - p_vars = p.p_vars; + { p with p_outputs = List.rev outputs } |