| 1 |
Require Import TestSuite.admit. |
| 2 |
Set Implicit Arguments. |
| 3 |
Generalizable All Variables. |
| 4 |
|
| 5 |
Polymorphic Record SpecializedCategory (obj : Type) := Build_SpecializedCategory' { |
| 6 |
Object :> _ := obj; |
| 7 |
Morphism' : obj -> obj -> Type; |
| 8 |
|
| 9 |
Identity' : forall o, Morphism' o o; |
| 10 |
Compose' : forall s d d', Morphism' d d' -> Morphism' s d -> Morphism' s d' |
| 11 |
}. |
| 12 |
|
| 13 |
Polymorphic Definition TypeCat : @SpecializedCategory Type |
| 14 |
:= (@Build_SpecializedCategory' Type |
| 15 |
(fun s d => s -> d) |
| 16 |
(fun _ => (fun x => x)) |
| 17 |
(fun _ _ _ f g => (fun x => f (g x)))). |
| 18 |
|
| 19 |
Inductive GraphIndex := GraphIndexSource | GraphIndexTarget. |
| 20 |
Polymorphic Definition GraphIndexingCategory : @SpecializedCategory GraphIndex. |
| 21 |
Admitted. |
| 22 |
|
| 23 |
Module success. |
| 24 |
#[universes(polymorphic)] |
| 25 |
Section SpecializedFunctor. |
| 26 |
Set Universe Polymorphism. |
| 27 |
Context `(C : @SpecializedCategory objC). |
| 28 |
Context `(D : @SpecializedCategory objD). |
| 29 |
Unset Universe Polymorphism. |
| 30 |
|
| 31 |
Polymorphic Record SpecializedFunctor |
| 32 |
:= { |
| 33 |
ObjectOf' : objC -> objD; |
| 34 |
MorphismOf' : forall s d, C.(Morphism') s d -> D.(Morphism') (ObjectOf' s) (ObjectOf' d) |
| 35 |
}. |
| 36 |
End SpecializedFunctor. |
| 37 |
|
| 38 |
Polymorphic Definition UnderlyingGraph : SpecializedFunctor GraphIndexingCategory TypeCat. |
| 39 |
Admitted. |
| 40 |
End success. |
| 41 |
|
| 42 |
Module success2. |
| 43 |
#[universes(polymorphic)] |
| 44 |
Section SpecializedFunctor. |
| 45 |
Polymorphic Context `(C : @SpecializedCategory objC). |
| 46 |
Polymorphic Context `(D : @SpecializedCategory objD). |
| 47 |
|
| 48 |
Polymorphic Record SpecializedFunctor |
| 49 |
:= { |
| 50 |
ObjectOf' : objC -> objD; |
| 51 |
MorphismOf' : forall s d, C.(Morphism') s d -> D.(Morphism') (ObjectOf' s) (ObjectOf' d) |
| 52 |
}. |
| 53 |
End SpecializedFunctor. |
| 54 |
|
| 55 |
Set Printing Universes. |
| 56 |
Polymorphic Definition UnderlyingGraph : SpecializedFunctor GraphIndexingCategory TypeCat. |
| 57 |
(* Toplevel input, characters 73-94: |
| 58 |
Error: |
| 59 |
The term "GraphIndexingCategory (* Top.563 *)" has type |
| 60 |
"SpecializedCategory (* Top.563 Set *) GraphIndex" |
| 61 |
while it is expected to have type |
| 62 |
"SpecializedCategory (* Top.550 Top.551 *) ?7" |
| 63 |
(Universe inconsistency: Cannot enforce Set = Top.551)). *) |
| 64 |
admit. |
| 65 |
Defined. |
| 66 |
End success2. |