Skip to content

Commit 02e6895

Browse files
chore: follow up on #8173 post-stage0 update
1 parent 551e755 commit 02e6895

File tree

10 files changed

+24
-24
lines changed

10 files changed

+24
-24
lines changed

src/Lean/BuiltinDocAttr.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ This allows the documentation of core Lean features to be visible without import
2222
are defined in. This is only useful during bootstrapping and should not be used outside of
2323
the Lean source code.
2424
-/
25-
@[builtin_init, builtin_doc]
26-
private def initFn :=
25+
@[builtin_doc]
26+
builtin_initialize
2727
registerBuiltinAttribute {
2828
name := `builtin_doc
2929
descr := "make the docs and location of this declaration available as a builtin"

src/Lean/Elab/InheritDoc.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ Uses documentation from a specified declaration.
1414
1515
`@[inherit_doc decl]` is used to inherit the documentation from the declaration `decl`.
1616
-/
17-
@[builtin_init, builtin_doc]
18-
private def init :=
17+
@[builtin_doc]
18+
builtin_initialize
1919
registerBuiltinAttribute {
2020
name := `inherit_doc
2121
descr := "inherit documentation from a specified declaration"

src/Lean/Elab/MutualDef.lean

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ Makes the bodies of definitions available to importing modules.
3232
This only has an effect if both the module the definition is defined in and the importing module
3333
have the module system enabled.
3434
-/
35-
@[builtin_init, builtin_doc]
36-
private def init :=
35+
@[builtin_doc]
36+
builtin_initialize
3737
registerBuiltinAttribute {
3838
name := `expose
3939
descr := "(module system) Make bodies of definitions available to importing modules."
@@ -49,8 +49,8 @@ be exposed in a section tagged `@[expose]`
4949
This only has an effect if both the module the definition is defined in and the importing module
5050
have the module system enabled.
5151
-/
52-
@[builtin_init, builtin_doc]
53-
private def init2 :=
52+
@[builtin_doc]
53+
builtin_initialize
5454
registerBuiltinAttribute {
5555
name := `no_expose
5656
descr := "(module system) Negate previous `[expose]` attribute."

src/Lean/Elab/Tactic/Monotonicity.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ Monotonicity theorems should have `Lean.Order.monotone ...` as a conclusion. The
3636
`monotonicity` tactic (scoped in the `Lean.Order` namespace) to automatically prove monotonicity
3737
for functions defined using `partial_fixpoint`.
3838
-/
39-
@[builtin_init, builtin_doc]
40-
private def init := registerBuiltinAttribute {
39+
@[builtin_doc]
40+
builtin_initialize registerBuiltinAttribute {
4141
name := `partial_fixpoint_monotone
4242
descr := "monotonicity theorem"
4343
add := fun decl _ kind => MetaM.run' do

src/Lean/Elab/Term.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2100,8 +2100,8 @@ builtin_initialize builtinIncrementalElabs : IO.Ref NameSet ← IO.mkRef {}
21002100
def addBuiltinIncrementalElab (decl : Name) : IO Unit := do
21012101
builtinIncrementalElabs.modify fun s => s.insert decl
21022102

2103-
@[builtin_init, inherit_doc incrementalAttr, builtin_doc]
2104-
private def init :=
2103+
@[inherit_doc incrementalAttr, builtin_doc]
2104+
builtin_initialize
21052105
registerBuiltinAttribute {
21062106
name := `builtin_incremental
21072107
descr := s!"(builtin) {incrementalAttr.attr.descr}"

src/Lean/Meta/Instances.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,8 @@ in particular for `opaque` instances.
242242
To assign priorities to instances, `@[instance prio]` can be used (where `prio` is a priority).
243243
This corresponds to the `instance (priority := prio)` notation.
244244
-/
245-
@[builtin_init, builtin_doc]
246-
private def init :=
245+
@[builtin_doc]
246+
builtin_initialize
247247
registerBuiltinAttribute {
248248
name := `instance
249249
descr := "type class instance"

src/Lean/Meta/Tactic/ElimInfo.lean

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -209,8 +209,8 @@ example (x : Three) (p : Three → Prop) : p x := by
209209
210210
`@[cases_eliminator]` works similarly for the `cases` tactic.
211211
-/
212-
@[builtin_init, builtin_doc]
213-
private def init : IO Unit :=
212+
@[builtin_doc]
213+
builtin_initialize
214214
registerBuiltinAttribute {
215215
name := `induction_eliminator
216216
descr := "custom `rec`-like eliminator for the `induction` tactic"
@@ -249,8 +249,8 @@ example (x : Three) (p : Three → Prop) : p x := by
249249
250250
`@[induction_eliminator]` works similarly for the `induction` tactic.
251251
-/
252-
@[builtin_init, builtin_doc]
253-
private def init2 : IO Unit :=
252+
@[builtin_doc]
253+
builtin_initialize
254254
registerBuiltinAttribute {
255255
name := `cases_eliminator
256256
descr := "custom `casesOn`-like eliminator for the `cases` tactic"

src/Lean/Meta/Tactic/Rfl.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ A reflexivity lemma should have the conclusion `r x x` where `r` is an arbitrary
3535
It is not possible to tag reflexivity lemmas for `=` using this attribute. These are handled as a
3636
special case in the `rfl` tactic.
3737
-/
38-
@[builtin_init, builtin_doc]
39-
private def initFn := registerBuiltinAttribute {
38+
@[builtin_doc]
39+
builtin_initialize registerBuiltinAttribute {
4040
name := `refl
4141
descr := "reflexivity relation"
4242
add := fun decl _ kind => MetaM.run' do

src/Lean/Meta/Tactic/Simp/SimpCongrTheorems.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ theorem Option.pbind_congr
136136
...
137137
```
138138
-/
139-
@[builtin_init, builtin_doc]
140-
private def init :=
139+
@[builtin_doc]
140+
builtin_initialize
141141
registerBuiltinAttribute {
142142
name := `congr
143143
descr := "congruence theorem"

src/Lean/Meta/Tactic/Symm.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ Tags symmetry lemmas to be used by the `symm` tactic.
3131
3232
A symmetry lemma should be of the form `r x y → r y x` where `r` is an arbitrary relation.
3333
-/
34-
@[builtin_init, builtin_doc]
35-
private def initFn := registerBuiltinAttribute {
34+
@[builtin_doc]
35+
builtin_initialize registerBuiltinAttribute {
3636
name := `symm
3737
descr := "symmetric relation"
3838
add := fun decl _ kind => MetaM.run' do

0 commit comments

Comments
 (0)