Skip to content

Commit d3c15b9

Browse files
chore: Update Lean to v4.29.0 (#76)
1 parent dc09042 commit d3c15b9

3 files changed

Lines changed: 14 additions & 12 deletions

File tree

LSpec/SlimCheck/Sampleable.lean

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,14 @@ class SampleableExt (α : Sort u) where
9191
sample : Gen proxy
9292
interp : proxy → α
9393

94-
attribute [instance] SampleableExt.proxyRepr
95-
attribute [instance] SampleableExt.shrink
94+
attribute [reducible, instance] SampleableExt.proxyRepr
95+
attribute [reducible, instance] SampleableExt.shrink
9696

9797
namespace SampleableExt
9898

9999
/-- Use to generate instance whose purpose is to simply generate values
100100
of a type directly using the `Gen` monad -/
101+
@[reducible]
101102
def mkSelfContained [Repr α] [Shrinkable α] (sample : Gen α) : SampleableExt α where
102103
proxy := α
103104
proxyRepr := inferInstance
@@ -176,6 +177,7 @@ instance Bool.sampleableExt : SampleableExt Bool :=
176177
/-- This can be specialized into customized `SampleableExt Char` instances.
177178
The resulting instance has `1 / length` chances of making an unrestricted choice of characters
178179
and it otherwise chooses a character from `chars` with uniform probabilities. -/
180+
@[reducible]
179181
def Char.sampleable (length : Nat) (chars : Array Char) : SampleableExt Char :=
180182
mkSelfContained do
181183
let x ← choose Nat 0 length

flake.lock

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lean-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
leanprover/lean4:v4.28.0
1+
leanprover/lean4:v4.29.0

0 commit comments

Comments
 (0)