diff options
author | 2016-01-13 00:20:46 +0100 | |
---|---|---|
committer | 2016-01-13 00:50:21 +0100 | |
commit | 2d568a895d5c8a246f497c94c79811d3aad4269f (patch) | |
tree | ea861b017fcc4526c94425bd11335c0c17c4fe95 /interp/topconstr.ml | |
parent | 9f8ae1aa2678944888d80ce0867bfb2bba0c8c71 (diff) |
Fixing #4467 (continued).
Function is_constructor was not properly fixed. Additionally, this fixes
a problem with the 8.5 interpretation of in-pattern (see Cases.v).
Diffstat (limited to 'interp/topconstr.ml')
-rw-r--r-- | interp/topconstr.ml | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/interp/topconstr.ml b/interp/topconstr.ml index 560cd0277..2cb2449b7 100644 --- a/interp/topconstr.ml +++ b/interp/topconstr.ml @@ -39,7 +39,9 @@ let error_invalid_pattern_notation loc = (* Functions on constr_expr *) let is_constructor id = - try ignore (Nametab.locate_extended (qualid_of_ident id)); true + try Globnames.isConstructRef + (Smartlocate.global_of_extended_global + (Nametab.locate_extended (qualid_of_ident id))) with Not_found -> false let rec cases_pattern_fold_names f a = function |