fix: remove unused try catch (#3794)

This fixes some placeholder code inadvertently contributed.
This commit is contained in:
Joe Hendrix 2024-03-27 18:39:51 -07:00 committed by GitHub
parent 4bacd70b3f
commit 7989f62f70
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -49,22 +49,16 @@ private def addImport (name : Name) (constInfo : ConstantInfo) :
match name with
| .str _ n => if n.endsWith "_inj" n.endsWith "_inj'" then return #[]
| _ => pure ()
try
withNewMCtxDepth do withReducible do
forallTelescopeReducing constInfo.type fun _ type => do
match type.getAppFnArgs with
| (``Eq, #[_, lhs, rhs])
| (``Iff, #[lhs, rhs]) => do
let a := Array.mkEmpty 2
let a := a.push (← InitEntry.fromExpr lhs (name, RwDirection.forward))
let a := a.push (← InitEntry.fromExpr rhs (name, RwDirection.backward))
pure a
| _ => return #[]
catch _e =>
throwError "Jhx. Timeout initializing entries"
-- if e.isMaxHeartbeat then
-- else
-- throw e
withNewMCtxDepth do withReducible do
forallTelescopeReducing constInfo.type fun _ type => do
match type.getAppFnArgs with
| (``Eq, #[_, lhs, rhs])
| (``Iff, #[lhs, rhs]) => do
let a := Array.mkEmpty 2
let a := a.push (← InitEntry.fromExpr lhs (name, RwDirection.forward))
let a := a.push (← InitEntry.fromExpr rhs (name, RwDirection.backward))
pure a
| _ => return #[]
/-- Configuration for `DiscrTree`. -/
def discrTreeConfig : WhnfCoreConfig := {}