sed -Ei 's/^(\s*)((private |protected )?(noncomputable )?(abbreviation|definition|meta_definition|theorem|lemma|proposition|corollary)\s+\S+\s*)((\s*\[(\S+(\s+[0-9]+)*|priority.*)\])+)\s*/\1attribute \6\n\1\2/' library/**/*.lean tests/**/*.lean sed -Ei 's/\s+$//' library/**/*.lean # remove trailing whitespace
11 lines
213 B
Text
11 lines
213 B
Text
import data.finset data.set
|
|
open finset set
|
|
|
|
attribute [coercion]
|
|
definition to_set {A : Type} (s : finset A) : set A := λ a, a ∈ s
|
|
|
|
constant P {A : Type} (s : set A) : Prop
|
|
|
|
variable s : finset nat
|
|
|
|
check P s
|