aboutsummaryrefslogtreecommitdiff
path: root/library
diff options
context:
space:
mode:
authorMaxime Dénès2017-05-05 15:36:58 +0200
committerMaxime Dénès2017-05-05 15:36:58 +0200
commit1b4b828c3045263aee55ac19e7b9ba45a4743af2 (patch)
tree73f7c9ed6210bc0449e0974d9dd20c79199718a1 /library
parent773d95f915996b581b7ea82d9193197649c951a0 (diff)
parent4361c1ed9ac5646055f9f0eecc4a003d720c1994 (diff)
Merge PR#544: Anonymous universes
Diffstat (limited to 'library')
-rw-r--r--library/declare.ml5
1 files changed, 2 insertions, 3 deletions
diff --git a/library/declare.ml b/library/declare.ml
index 31c9c24bc3..91e0cb44b3 100644
--- a/library/declare.ml
+++ b/library/declare.ml
@@ -514,11 +514,10 @@ let do_constraint poly l =
match x with
| GProp -> Loc.dummy_loc, (false, Univ.Level.prop)
| GSet -> Loc.dummy_loc, (false, Univ.Level.set)
- | GType None ->
+ | GType None | GType (Some (_, Anonymous)) ->
user_err ~hdr:"Constraint"
(str "Cannot declare constraints on anonymous universes")
- | GType (Some (loc, id)) ->
- let id = Id.of_string id in
+ | GType (Some (loc, Name id)) ->
let names, _ = Global.global_universe_names () in
try loc, Idmap.find id names
with Not_found ->