f177082c3b
@avigad and @fpvandoorn, I changed the metaclasses names. They were not uniform: - The plural was used in some cases (e.g., [coercions]). - In other cases a cryptic name was used (e.g., [brs]). Now, I tried to use the attribute name as the metaclass name whenever possible. For example, we write definition foo [coercion] ... definition bla [forward] ... and open [coercion] nat open [forward] nat It is easier to remember and is uniform.
39 lines
582 B
Text
39 lines
582 B
Text
section
|
|
check (1:nat) + 2
|
|
check add
|
|
end
|
|
|
|
section
|
|
variable a : nat
|
|
check a + a
|
|
check add a a
|
|
check a + 1
|
|
end
|
|
|
|
section
|
|
open - [class] nat
|
|
variable a : nat
|
|
check a + a
|
|
check add a a
|
|
check a + 1
|
|
definition foo1 : inhabited nat :=
|
|
_ -- Error inhabited instances was not loaded
|
|
end
|
|
|
|
section
|
|
open - [class] [decl] nat
|
|
variable a : nat
|
|
check a + a
|
|
check a + 1
|
|
definition foo2 : inhabited nat :=
|
|
_ -- Error inhabited instances was not loaded
|
|
end
|
|
|
|
section
|
|
open [class] nat
|
|
definition foo3 : inhabited nat :=
|
|
_
|
|
|
|
variable a : nat
|
|
check a + a
|
|
end
|