Skip to content

Conversation

cuviper
Copy link
Member

@cuviper cuviper commented May 9, 2020

This manually reverts the new implementations from pull request #136. As
noted in issue #150, the mere existence of those impls can have a bad
effect on type inference in other parts of a crate, even from afar. All
comparisons of primitives with an unknown type become ambiguous whether
that's meant to compare with itself or a bigint, even if num-bigint is
not directly in scope at all.

Since this can break unrelated code in surprising ways, I think it's not
wise for us to have these implementations. Maybe we can explore other
methods to compare with primitives in the future, though it won't be as
convenient as using the operators.

This manually reverts the new implementations from pull request rust-num#136. As
noted in issue rust-num#150, the mere existence of those impls can have a bad
effect on type inference in other parts of a crate, even from afar. All
comparisons of primitives with an unknown type become ambiguous whether
that's meant to compare with itself or a bigint, even if `num-bigint` is
not directly in scope at all.

Since this can break unrelated code in surprising ways, I think it's not
wise for us to have these implementations. Maybe we can explore other
methods to compare with primitives in the future, though it won't be as
convenient as using the operators.
@cuviper
Copy link
Member Author

cuviper commented Jun 1, 2020

bors r+

@bors
Copy link
Contributor

bors bot commented Jun 1, 2020

@bors bors bot merged commit 5e6c262 into rust-num:master Jun 1, 2020
@cuviper cuviper mentioned this pull request Jun 12, 2020
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant