@@ -6,11 +6,11 @@ import Mathlib.Tactic.Common
6
6
/-! Tests for the `setOption` linter -/
7
7
section setOption
8
8
9
- -- The warning generated by `linter.setOption` is not suppressed by `#guard_msgs`,
9
+ -- The warning generated by `linter.style. setOption` is not suppressed by `#guard_msgs`,
10
10
-- because the linter is run on `#guard_msgs` itself. This is a known issue, see e.g.
11
11
-- https://leanprover.zulipchat.com/#narrow/stream/348111-batteries/topic/unreachableTactic.20linter.20not.20suppressed.20by.20.60.23guard_msgs.60
12
12
-- We jump through an extra hoop here to silence the warning.
13
- set_option linter.setOption false
13
+ set_option linter.style. setOption false
14
14
15
15
-- All types of options are supported: boolean, numeric and string-valued.
16
16
-- On the top level, i.e. as commands.
@@ -19,60 +19,60 @@ set_option linter.setOption false
19
19
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
20
20
for development and not for final code. If you intend to submit this contribution to the
21
21
Mathlib project, please remove 'set_option pp.all'.
22
- note: this linter can be disabled with `set_option linter.setOption false`
22
+ note: this linter can be disabled with `set_option linter.style. setOption false`
23
23
-/
24
24
#guard_msgs in
25
- set_option linter.setOption true in
25
+ set_option linter.style. setOption true in
26
26
set_option pp.all true
27
27
28
28
/--
29
29
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
30
30
for development and not for final code. If you intend to submit this contribution to the
31
31
Mathlib project, please remove 'set_option profiler'.
32
- note: this linter can be disabled with `set_option linter.setOption false`
32
+ note: this linter can be disabled with `set_option linter.style. setOption false`
33
33
-/
34
34
#guard_msgs in
35
- set_option linter.setOption true in
35
+ set_option linter.style. setOption true in
36
36
set_option profiler false
37
37
38
38
/--
39
39
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
40
40
for development and not for final code. If you intend to submit this contribution to the
41
41
Mathlib project, please remove 'set_option pp.all'.
42
- note: this linter can be disabled with `set_option linter.setOption false`
42
+ note: this linter can be disabled with `set_option linter.style. setOption false`
43
43
-/
44
44
#guard_msgs in
45
- set_option linter.setOption true in
45
+ set_option linter.style. setOption true in
46
46
set_option pp.all false
47
47
48
48
/--
49
49
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
50
50
for development and not for final code. If you intend to submit this contribution to the
51
51
Mathlib project, please remove 'set_option profiler.threshold'.
52
- note: this linter can be disabled with `set_option linter.setOption false`
52
+ note: this linter can be disabled with `set_option linter.style. setOption false`
53
53
-/
54
54
#guard_msgs in
55
- set_option linter.setOption true in
55
+ set_option linter.style. setOption true in
56
56
set_option profiler.threshold 50
57
57
58
58
/--
59
59
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
60
60
for development and not for final code. If you intend to submit this contribution to the
61
61
Mathlib project, please remove 'set_option trace.profiler.output'.
62
- note: this linter can be disabled with `set_option linter.setOption false`
62
+ note: this linter can be disabled with `set_option linter.style. setOption false`
63
63
-/
64
64
#guard_msgs in
65
- set_option linter.setOption true in
65
+ set_option linter.style. setOption true in
66
66
set_option trace.profiler.output "foo"
67
67
68
68
/--
69
69
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
70
70
for development and not for final code. If you intend to submit this contribution to the
71
71
Mathlib project, please remove 'set_option debug.moduleNameAtTimeout'.
72
- note: this linter can be disabled with `set_option linter.setOption false`
72
+ note: this linter can be disabled with `set_option linter.style. setOption false`
73
73
-/
74
74
#guard_msgs in
75
- set_option linter.setOption true in
75
+ set_option linter.style. setOption true in
76
76
set_option debug.moduleNameAtTimeout false
77
77
78
78
-- The lint does not fire on arbitrary options.
@@ -84,10 +84,10 @@ set_option autoImplicit false
84
84
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
85
85
for development and not for final code. If you intend to submit this contribution to the
86
86
Mathlib project, please remove 'set_option pp.all'.
87
- note: this linter can be disabled with `set_option linter.setOption false`
87
+ note: this linter can be disabled with `set_option linter.style. setOption false`
88
88
-/
89
89
#guard_msgs in
90
- set_option linter.setOption true in
90
+ set_option linter.style. setOption true in
91
91
lemma tactic : True := by
92
92
set_option pp.all true in
93
93
trivial
@@ -96,10 +96,10 @@ lemma tactic : True := by
96
96
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
97
97
for development and not for final code. If you intend to submit this contribution to the
98
98
Mathlib project, please remove 'set_option pp.raw.maxDepth'.
99
- note: this linter can be disabled with `set_option linter.setOption false`
99
+ note: this linter can be disabled with `set_option linter.style. setOption false`
100
100
-/
101
101
#guard_msgs in
102
- set_option linter.setOption true in
102
+ set_option linter.style. setOption true in
103
103
lemma tactic2 : True := by
104
104
set_option pp.raw.maxDepth 32 in
105
105
trivial
@@ -108,10 +108,10 @@ lemma tactic2 : True := by
108
108
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
109
109
for development and not for final code. If you intend to submit this contribution to the
110
110
Mathlib project, please remove 'set_option pp.all'.
111
- note: this linter can be disabled with `set_option linter.setOption false`
111
+ note: this linter can be disabled with `set_option linter.style. setOption false`
112
112
-/
113
113
#guard_msgs in
114
- set_option linter.setOption true in
114
+ set_option linter.style. setOption true in
115
115
lemma tactic3 : True := by
116
116
set_option pp.all false in
117
117
trivial
@@ -120,10 +120,10 @@ lemma tactic3 : True := by
120
120
warning: Setting options starting with 'debug', 'pp', 'profiler', 'trace' is only intended
121
121
for development and not for final code. If you intend to submit this contribution to the
122
122
Mathlib project, please remove 'set_option trace.profiler.output'.
123
- note: this linter can be disabled with `set_option linter.setOption false`
123
+ note: this linter can be disabled with `set_option linter.style. setOption false`
124
124
-/
125
125
#guard_msgs in
126
- set_option linter.setOption true in
126
+ set_option linter.style. setOption true in
127
127
lemma tactic4 : True := by
128
128
set_option trace.profiler.output "foo" in
129
129
trivial
0 commit comments