aboutsummaryrefslogtreecommitdiff
path: root/test-suite
diff options
context:
space:
mode:
authorMatthieu Sozeau2016-06-29 11:55:31 +0200
committerMatthieu Sozeau2016-06-29 11:55:31 +0200
commit5e979cf6020eea9fa0feaa77c7436a29443e35db (patch)
tree7f2d28d1bfb9dfb72788b434ecada5603afecb57 /test-suite
parent58b6784fee71a16719bc4f268dc42830c06a5c63 (diff)
parent40ee96a0392fbc0945c48b5b134aa1be36f86225 (diff)
Merge branch 'bug4527' into trunk
Diffstat (limited to 'test-suite')
-rw-r--r--test-suite/bugs/closed/4726.v19
1 files changed, 19 insertions, 0 deletions
diff --git a/test-suite/bugs/closed/4726.v b/test-suite/bugs/closed/4726.v
new file mode 100644
index 0000000000..0037b6fdea
--- /dev/null
+++ b/test-suite/bugs/closed/4726.v
@@ -0,0 +1,19 @@
+Set Universe Polymorphism.
+
+Definition le@{i j} : Type@{j} :=
+ (fun A : Type@{j} => A)
+ (unit : Type@{i}).
+Definition eq@{i j} : Type@{j} := let x := le@{i j} in le@{j i}.
+
+Record Inj@{i j} (A : Type@{i}) (B : Type@{j}) : Type@{j} :=
+ { inj : A }.
+
+Monomorphic Universe u1.
+Let ty1 : Type@{u1} := Set.
+Check Inj@{Set u1}.
+(* Would fail with univ inconsistency if the universe was minimized *)
+
+Record Inj'@{i j} (A : Type@{i}) (B : Type@{j}) : Type@{j} :=
+ { inj' : A; foo : Type@{j} := eq@{i j} }.
+Fail Check Inj'@{Set u1}. (* Do not drop constraint i = j *)
+Check Inj'@{Set Set}.