Skip to content

Commit

Permalink
fix: don't generate code for decls with an implemented_by attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
zwarich committed Jan 17, 2025
1 parent e3fd954 commit 7362de4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Lean/Compiler/LCNF/Main.lean
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def shouldGenerateCode (declName : Name) : CoreM Bool := do
let some info ← getDeclInfo? declName | return false
unless info.hasValue (allowOpaque := true) do return false
if hasMacroInlineAttribute env declName then return false
if (getImplementedBy? env declName).isSome then return false
if (← Meta.isMatcher declName) then return false
if isCasesOnRecursor env declName then return false
-- TODO: check if type class instance
Expand Down

0 comments on commit 7362de4

Please sign in to comment.