Skip to content

Commit 8580d0e

Browse files
committed
Update a few tests
1 parent 5ee79ed commit 8580d0e

File tree

8 files changed

+12
-12
lines changed

8 files changed

+12
-12
lines changed

tests/lean/run/issue2171.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ def g (n : Nat) : Nat :=
33
1
44
else
55
4 + g (n - 1)
6-
termination_by n
6+
termination_by (n,0)
77
decreasing_by simp_wf; omega
88

99
example : g 10000 = id g (id 10000) := rfl

tests/lean/run/letToHaveCleanup.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def fnWFRec (n : Nat) : let α := Nat; α :=
168168
| 0 => 0
169169
| n + 1 => id (let m := n + 1; m * fnWFRec (n / 2))
170170
/--
171-
info: @[irreducible] def fnWFRec : Nat →
171+
info: def fnWFRec : Nat →
172172
have α : Type := Nat;
173173
α :=
174174
WellFounded.Nat.fix (fun x => x) fun n a =>

tests/lean/run/mutwf2.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@ mutual
1111
end
1212

1313
/--
14-
info: @[irreducible] def Ex1.isEven : Nat → Bool :=
14+
info: def Ex1.isEven : Nat → Bool :=
1515
fun a => isEven._mutual (PSum.inl a)
1616
-/
1717
#guard_msgs in
1818
#print isEven
1919

2020
/--
21-
info: @[irreducible] def Ex1.isOdd : Nat → Bool :=
21+
info: def Ex1.isOdd : Nat → Bool :=
2222
fun a => isEven._mutual (PSum.inr a)
2323
-/
2424
#guard_msgs in

tests/lean/run/structuralEqn6.lean

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ where
3434

3535
/--
3636
info: equations:
37-
@[defeq] theorem trailingZeros'.aux.eq_1 : ∀ (i : Int) (hi : i ≠ 0) (acc k_2 : Nat) (x_1 : k_2 + 1 ≠ 0)
37+
theorem trailingZeros'.aux.eq_1 : ∀ (i : Int) (hi : i ≠ 0) (acc k_2 : Nat) (x_1 : k_2 + 1 ≠ 0)
3838
(hk_2 : i.natAbs ≤ k_2 + 1),
3939
trailingZeros'.aux k_2.succ i hi hk_2 acc =
4040
if h : i % 2 = 0 then trailingZeros'.aux k_2 (i / 2) ⋯ ⋯ (acc + 1) else acc
@@ -77,7 +77,7 @@ where
7777

7878
/--
7979
info: equations:
80-
@[defeq] theorem trailingZeros2'.aux.eq_1 : ∀ (i : Int) (hi : i ≠ 0) (acc k_2 : Nat) (hk_2 : i.natAbs ≤ k_2 + 1),
80+
theorem trailingZeros2'.aux.eq_1 : ∀ (i : Int) (hi : i ≠ 0) (acc k_2 : Nat) (hk_2 : i.natAbs ≤ k_2 + 1),
8181
trailingZeros2'.aux k_2.succ i hi hk_2 acc =
8282
if h : i % 2 = 0 then trailingZeros2'.aux k_2 (i / 2) ⋯ ⋯ (acc + 1) else acc
8383
@[defeq] theorem trailingZeros2'.aux.eq_2 : ∀ (i : Int) (hi : i ≠ 0) (acc : Nat) (hk_2 : i.natAbs ≤ 0),

tests/lean/run/wfEqns5.lean

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ termination_by n => n
88
info: equations:
99
@[defeq] theorem foo.eq_1 : foo 0 0 = 0
1010
theorem foo.eq_2 : ∀ (x : Nat), (x = 0 → False) → foo 0 x = x
11-
@[defeq] theorem foo.eq_3 : ∀ (x n : Nat), foo n.succ x = foo n x
11+
theorem foo.eq_3 : ∀ (x n : Nat), foo n.succ x = foo n x
1212
-/
1313
#guard_msgs in
1414
#print equations foo
@@ -58,7 +58,7 @@ info: equations:
5858
match x with
5959
| 0 => 0
6060
| m => m
61-
@[defeq] theorem bar.eq_2 : ∀ (x n : Nat), bar n.succ x = bar n x
61+
theorem bar.eq_2 : ∀ (x n : Nat), bar n.succ x = bar n x
6262
-/
6363
#guard_msgs in
6464
#print equations bar
@@ -125,7 +125,7 @@ info: equations:
125125
match x with
126126
| 0 => 0
127127
| m => m
128-
@[defeq] theorem Structural.bar.eq_2 : ∀ (x n : Nat), bar n.succ x = bar n x
128+
theorem Structural.bar.eq_2 : ∀ (x n : Nat), bar n.succ x = bar n x
129129
-/
130130
#guard_msgs in
131131
#print equations bar

tests/lean/wfrecUnusedLet.lean.expected.out

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@[irreducible] def f : Nat → Nat :=
1+
def f : Nat → Nat :=
22
WellFounded.Nat.fix (fun x => x) fun n a =>
33
if h : n = 0 then 1
44
else

tests/pkg/module/Module/ImportedAll.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ info: private theorem f_struct.eq_unfold : f_struct = fun x =>
7777
-/
7878
#guard_msgs in #print sig f_struct.eq_unfold
7979

80-
/-- info: private theorem f_wfrec.eq_1 : ∀ (x : Nat), f_wfrec 0 x = x -/
80+
/-- info: @[defeq] private theorem f_wfrec.eq_1 : ∀ (x : Nat), f_wfrec 0 x = x -/
8181
#guard_msgs(pass trace, all) in #print sig f_wfrec.eq_1
8282

8383
/--

tests/pkg/module/Module/NonModule.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ info: theorem f_struct.eq_unfold : f_struct = fun x =>
2626
-/
2727
#guard_msgs in #print sig f_struct.eq_unfold
2828

29-
/-- info: theorem f_wfrec.eq_1 : ∀ (x : Nat), f_wfrec 0 x = x -/
29+
/-- info: @[defeq] theorem f_wfrec.eq_1 : ∀ (x : Nat), f_wfrec 0 x = x -/
3030
#guard_msgs(pass trace, all) in #print sig f_wfrec.eq_1
3131

3232
/--

0 commit comments

Comments
 (0)