diff options
Diffstat (limited to 'src/toFromInterp_lib_bitlist.ml')
| -rw-r--r-- | src/toFromInterp_lib_bitlist.ml | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/toFromInterp_lib_bitlist.ml b/src/toFromInterp_lib_bitlist.ml index d47beca3..13912722 100644 --- a/src/toFromInterp_lib_bitlist.ml +++ b/src/toFromInterp_lib_bitlist.ml @@ -106,6 +106,19 @@ let zvectorToInterpValue typq_'n typq_'ord typq_'a v = let vectorFromInterpValue = zvectorFromInterpValue let vectorToInterpValue = zvectorToInterpValue +let zbitvectorFromInterpValue typq_'n typq_'ord v = match v with + | V_vector vs -> + assert (Big_int.of_int (List.length vs) = typq_'n); + vs + | _ -> failwith "invalid interpreter value for vector" + +let zbitvectorToInterpValue typq_'n typq_'ord v = + assert (Big_int.of_int (List.length v) = typq_'n); + V_vector v + +let bitvectorFromInterpValue = zvectorFromInterpValue +let bitvectorToInterpValue = zvectorToInterpValue + let zbitFromInterpValue v = match v with | V_bit b -> (match b with | Sail_lib.B0 -> BitT.b0 |
