diff options
| author | Christopher Pulte | 2015-10-06 11:38:01 +0100 |
|---|---|---|
| committer | Christopher Pulte | 2015-10-06 11:38:01 +0100 |
| commit | 18fcc8f8f587839df1fadcfcd5a950c6b817b09b (patch) | |
| tree | e28900d369784f242f831bbac458319a57769466 /src | |
| parent | b0c3b70ea6645cd8d172ffadc8e7877d7b88028a (diff) | |
fixes
Diffstat (limited to 'src')
| -rw-r--r-- | src/rewriter.ml | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/rewriter.ml b/src/rewriter.ml index ceae3462..3f6e9a85 100644 --- a/src/rewriter.ml +++ b/src/rewriter.ml @@ -685,7 +685,14 @@ let remove_vector_concat_pat pat = (_,Base((_,{t = Tapp ("vector", [_;TA_nexp {nexp = Nconst length};_;_])}),_,_,_,_)) -> let wild _ = P_aux (P_wild,(Parse_ast.Unknown,simple_annot {t = Tid "bit"})) in acc @ (List.map wild (range 0 ((int_of_big_int length) - 1))) - | _,(l,_) -> raise (Reporting_basic.err_unreachable l "remove_vector_concats: Non-vector in vector-concat pattern") in + | P_wild, + (_,Base((_,{t = Tapp ("vector", [_;TA_nexp {nexp = Nconst length};_;_])}),_,_,_,_)) -> + let wild _ = P_aux (P_wild,(Parse_ast.Unknown,simple_annot {t = Tid "bit"})) in + acc @ (List.map wild (range 0 ((int_of_big_int length) - 1))) + | P_lit _,(l,_) -> + raise (Reporting_basic.err_unreachable l "remove_vector_concats: P_lit pattern in vector-concat pattern") + | _,(l,_) -> + raise (Reporting_basic.err_unreachable l "remove_vector_concats: Non-vector in vector-concat pattern") in P_vector (List.fold_left aux [] ps) in {id_pat_alg with p_vector_concat = p_vector_concat} in |
