summaryrefslogtreecommitdiff
path: root/src/Substitute.ml
diff options
context:
space:
mode:
Diffstat (limited to 'src/Substitute.ml')
-rw-r--r--src/Substitute.ml2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Substitute.ml b/src/Substitute.ml
index 4a1f42eb..0bc612ea 100644
--- a/src/Substitute.ml
+++ b/src/Substitute.ml
@@ -120,6 +120,8 @@ let type_decl_get_instantiated_variants_fields_rtypes (def : T.type_decl)
(fun i v -> (Some (T.VariantId.of_int i), v.T.fields))
variants
| T.Struct fields -> [ (None, fields) ]
+ | T.Opaque ->
+ raise (Failure "Can't retrieve the variants of an opaque type")
in
List.map
(fun (id, fields) ->