summaryrefslogtreecommitdiff
path: root/typing
diff options
context:
space:
mode:
authorJacques Garrigue <garrigue at math.nagoya-u.ac.jp>2013-01-15 05:22:28 +0000
committerJacques Garrigue <garrigue at math.nagoya-u.ac.jp>2013-01-15 05:22:28 +0000
commit0944e977232942ed35425a3f803a942e219cee76 (patch)
tree5dc5a8bc0ebe931abcde47f0eda0e4b87952a4c2 /typing
parent4abe4a82ca54e649397910b4b4b14fb322d0cb28 (diff)
downloadocaml-0944e977232942ed35425a3f803a942e219cee76.tar.gz
allow absent constructors in PM for non-exact polymorphic variant types
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13235 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Diffstat (limited to 'typing')
-rw-r--r--typing/typecore.ml1
1 files changed, 1 insertions, 0 deletions
diff --git a/typing/typecore.ml b/typing/typecore.ml
index 69089e38c2..7943420587 100644
--- a/typing/typecore.ml
+++ b/typing/typecore.ml
@@ -1719,6 +1719,7 @@ let check_absent_variant env =
let row = row_repr !row in
if List.exists (fun (s',fi) -> s = s' && row_field_repr fi <> Rabsent)
row.row_fields
+ || not row.row_fixed && not (static_row row) (* same as Ctype.poly *)
then () else
let ty_arg =
match arg with None -> [] | Some p -> [correct_levels p.pat_type] in