Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

slow typeclass synthesis: takes 16000 heartbeats to fail on NonUnitalNonAssocSemiring (elementalStarAlgebra ℂ x) #12227

Open
semorrison opened this issue Apr 18, 2024 · 1 comment

Comments

@semorrison
Copy link
Contributor

import Mathlib

/--
error: failed to synthesize
  NonUnitalNonAssocSemiring ↥(elementalStarAlgebra ℂ x)
(deterministic) timeout at 'typeclass', maximum number of heartbeats (16000) has been reached (use 'set_option synthInstance.maxHeartbeats <num>' to set the limit)
-/
#guard_msgs in
set_option synthInstance.maxHeartbeats 16000 in
variable {A : Type} [NormedRing A] [NormedAlgebra ℂ A] [StarRing A]
  [CstarRing A] [StarModule ℂ A] (x : A) in
#synth NonUnitalNonAssocSemiring (elementalStarAlgebra ℂ x)

-- This gets slightly worse on `nightly-testing` after https://github.com/leanprover/lean4/pull/3807,
-- and causes the simpNF failure on `elementalStarAlgebra.characterSpaceToSpectrum_coe`
@mattrobball
Copy link
Collaborator

Also fixed by leanprover/lean4#4085

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants