Debian Codegraph @

test-suite/output/Inductive.v

raw
1 Fail Inductive list' (A:Set) : Set :=
2 | nil' : list' A
3 | cons' : A -> list' A -> list' (A*A).
4
5 (* Check printing of let-ins *)
6 Inductive foo (A : Type) (x : A) (y := x) := Foo.
7
8 Print foo.
9
10 (* Check where clause *)
11 Reserved Notation "x ** y" (at level 40, left associativity).
12 Inductive myprod A B :=
13 mypair : A -> B -> A ** B
14 where "A ** B" := (myprod A B) (only parsing).
15
16 Check unit ** bool.
17
18 (* "option is template" *)
19 About option.
20 Set Printing Universes.
21 About option.
22 (* "option is template on xxx" *)
23
24 Module DiffParams.
25 Fail Inductive B: Type :=
26 | F: A -> B with
27 Inductive A: Type := mkA.
28
29 Fail Inductive B := { x : nat } with
30 Inductive A := { y : nat }.
31 End DiffParams.
32
33 (* print squash info
34 (can't test impredicative set squashes in this file) *)
35
36 About or.
37
38 Inductive sunit : SProp := stt.
39
40 About sunit.
41
42 Set Universe Polymorphism.
43
44 Polymorphic Inductive sempty@{q; |} : Type@{q;Set} := .
45
46 About sempty.
47
48 Polymorphic Inductive ssig@{q1 q2 q3;a b|}
49 (A:Type@{q1;a})
50 (B:A -> Type@{q2;b})
51 : Type@{q3;max(a,b)}
52 := sexist (a:A) (b:B a).
53
54 About ssig.
55
56 Polymorphic Inductive BoxP@{q;a|} (A:Type@{q;a}) : Prop := boxP (_:A).
57
58 About BoxP.