diff options
author | Stefan Muenzel <source@s.muenzel.net> | 2023-03-27 15:37:52 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-27 10:37:52 +0200 |
commit | b45983abffc2ab07c34c3f686fda08f3d4c5e954 (patch) | |
tree | 53a0d40d7fe6db098d56b5b7cf30e574f887c2c9 /typing/printtyp.ml | |
parent | 745b2243169fbdecce6de67175f5d3621e18e531 (diff) | |
download | ocaml-b45983abffc2ab07c34c3f686fda08f3d4c5e954.tar.gz |
Print the type variable that cannot be generalized (#12051)
Diffstat (limited to 'typing/printtyp.ml')
-rw-r--r-- | typing/printtyp.ml | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/typing/printtyp.ml b/typing/printtyp.ml index b14b4feab8..42b11a4d21 100644 --- a/typing/printtyp.ml +++ b/typing/printtyp.ml @@ -1123,7 +1123,7 @@ let rec tree_of_typexp mode ty = let tpath = tree_of_best_type_path p p' in Otyp_constr (tpath, tree_of_typlist mode tyl') | Tvariant row -> - let Row {fields; name; closed} = row_repr row in + let Row {fields; name; closed; _} = row_repr row in let fields = if closed then List.filter (fun (_, f) -> row_field_repr f <> Rabsent) @@ -1281,9 +1281,11 @@ let shared_type_scheme ppf ty = prepare_type ty; typexp Type_scheme ppf ty +let prepared_type_scheme ppf ty = typexp Type_scheme ppf ty + let type_scheme ppf ty = prepare_for_printing [ty]; - typexp Type_scheme ppf ty + prepared_type_scheme ppf ty let type_path ppf p = let (p', s) = best_type_path p in |