Skip to content

Commit

Permalink
Fix error with Record_unboxed (bug in block kind patch) (ocaml#119)
Browse files Browse the repository at this point in the history
  • Loading branch information
mshinwell committed Aug 4, 2021
1 parent 2e251fc commit c0e225e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion ocaml/typing/typeopt.ml
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,12 @@ let value_kind env ty =
| Record_inlined tag ->
Pblock { tag; fields }
| Record_unboxed _ ->
assert false
begin match fields with
| [field] -> field
| [] | _::_ ->
Misc.fatal_error "Records that are [Record_unboxed] should \
have exactly one field"
end
| Record_extension _ ->
Pgenval
end
Expand Down

0 comments on commit c0e225e

Please sign in to comment.