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

[Merged by Bors] - feat(algebra/opposites): more scalar action instances #8672

Closed
wants to merge 3 commits into from

Conversation

eric-wieser
Copy link
Member

@eric-wieser eric-wieser commented Aug 14, 2021

This adds weaker and stronger versions of monoid.to_opposite_mul_action for has_mul, monoid_with_zero, and semiring. It also adds an smul_comm_class instance.


Open in Gitpod

The motivation here was to help provide the instance in this Zulip thread

@eric-wieser eric-wieser added the awaiting-review The author would like community review of the PR label Aug 14, 2021
Copy link
Member

@PatrickMassot PatrickMassot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bors d+

@@ -241,6 +241,12 @@ instance semiring.to_module [semiring R] : module R R :=
zero_smul := zero_mul,
smul_zero := mul_zero }

@[priority 910] -- see Note [lower instance priority]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any motivation for this very specific value?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've no idea, I just copied it from the analogous instance for left-multiplication.

@bors
Copy link

bors bot commented Aug 15, 2021

✌️ eric-wieser can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@github-actions github-actions bot added delegated The PR author may merge after reviewing final suggestions. and removed awaiting-review The author would like community review of the PR labels Aug 15, 2021
@eric-wieser
Copy link
Member Author

bors r+

@github-actions github-actions bot added the ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) label Aug 15, 2021
bors bot pushed a commit that referenced this pull request Aug 15, 2021
This adds weaker and stronger versions of `monoid.to_opposite_mul_action` for `has_mul`, `monoid_with_zero`, and `semiring`. It also adds an `smul_comm_class` instance.
@bors
Copy link

bors bot commented Aug 15, 2021

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(algebra/opposites): more scalar action instances [Merged by Bors] - feat(algebra/opposites): more scalar action instances Aug 15, 2021
@bors bors bot closed this Aug 15, 2021
@bors bors bot deleted the eric-wieser/more-opposite-actions branch August 15, 2021 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
delegated The PR author may merge after reviewing final suggestions. ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants