fix: mark auxiliary noConfusion declarations for enumeration types as [reducible]
closes #1016
This commit is contained in:
parent
ee9fcd30e8
commit
aa63fda835
2 changed files with 8 additions and 0 deletions
|
|
@ -64,6 +64,7 @@ where
|
|||
safety := DefinitionSafety.safe
|
||||
hints := ReducibilityHints.abbrev
|
||||
}
|
||||
setReducibleAttribute declName
|
||||
|
||||
mkNoConfusionType : MetaM Unit := do
|
||||
let enumType := mkConst enumName
|
||||
|
|
@ -83,6 +84,7 @@ where
|
|||
safety := DefinitionSafety.safe
|
||||
hints := ReducibilityHints.abbrev
|
||||
}
|
||||
setReducibleAttribute declName
|
||||
|
||||
mkNoConfusion : MetaM Unit := do
|
||||
let enumType := mkConst enumName
|
||||
|
|
@ -105,6 +107,7 @@ where
|
|||
safety := DefinitionSafety.safe
|
||||
hints := ReducibilityHints.abbrev
|
||||
}
|
||||
setReducibleAttribute declName
|
||||
|
||||
def mkNoConfusion (declName : Name) : MetaM Unit := do
|
||||
if (← isEnumType declName) then
|
||||
|
|
|
|||
5
tests/lean/run/1016.lean
Normal file
5
tests/lean/run/1016.lean
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
inductive t | one | two
|
||||
|
||||
example (h : False) : t.one = t.two := by
|
||||
simp
|
||||
contradiction
|
||||
Loading…
Add table
Reference in a new issue