-
Notifications
You must be signed in to change notification settings - Fork 316
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
refactor: deprecate ContinuousMonoidHomClass
#17558
base: master
Are you sure you want to change the base?
Conversation
Use `[ContinuousMapClass ..] [MonoidHomClass ..]` instead.
PR summary 29a5790d8cImport changes for modified filesNo significant changes to the import graph Import changes for all files
|
!bench |
Here are the benchmark results for commit 22af102. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that FunLike
is not extended, this makes a lot of sense.
maintainer merge
🚀 Pull request has been placed on the maintainer queue by YaelDillies. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bors d+
Thanks!
@@ -30,49 +30,43 @@ variable (F A B C D E : Type*) [Monoid A] [Monoid B] [Monoid C] [Monoid D] [Comm | |||
/-- The type of continuous additive monoid homomorphisms from `A` to `B`. | |||
When possible, instead of parametrizing results over `(f : ContinuousAddMonoidHom A B)`, | |||
you should parametrize over `(F : Type*) [ContinuousAddMonoidHomClass F A B] (f : F)`. | |||
you should parametrize | |||
over `(F : Type*) [FunLike F A B] [ContinuousMapClass F A B] [AddMonoidHomClass F A B] (f : F)`. | |||
When you extend this structure, make sure to extend `ContinuousAddMonoidHomClass`. -/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you adapt the docstring to the new setting?
@[to_additive] | ||
theorem toContinuousMap_injective : Injective (toContinuousMap : _ → C(A, B)) := fun f g h => | ||
ext <| by convert DFunLike.ext_iff.1 h | ||
|
||
-- Porting note: Removed simps because given definition is not a constructor application | ||
/-- Construct a `ContinuousMonoidHom` from a `Continuous` `MonoidHom`. -/ | ||
@[to_additive "Construct a `ContinuousAddMonoidHom` from a `Continuous` `AddMonoidHom`."] | ||
@[to_additive (attr := deprecated (since := "2024-10-08")) | ||
"Construct a `ContinuousAddMonoidHom` from a `Continuous` `AddMonoidHom`."] | ||
def mk' (f : A →* B) (hf : Continuous f) : ContinuousMonoidHom A B := |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it's defeq to something already existing, could you rather write it as a deprecated alias, to make sure that people who were using it get the suggestion to use mk
instead?
✌️ urkud can now approve this pull request. To approve and merge a pull request, simply reply with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks 🎉
bors merge
bors r- |
Canceled. |
Use
[ContinuousMapClass ..] [MonoidHomClass ..]
instead. Also deprecatemk'
since it's defeqmk
.