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

fixed eqv alias issue #2513: #2521

Merged
merged 3 commits into from
Sep 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions core/src/main/scala/cats/syntax/eq.scala
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ trait EqSyntax {
final class EqOps[A: Eq](lhs: A) {
def ===(rhs: A): Boolean = macro Ops.binop[A, Boolean]
def =!=(rhs: A): Boolean = macro Ops.binop[A, Boolean]
def eqv(rhs: A): Boolean = Eq[A].eqv(lhs, rhs)
def neqv(rhs: A): Boolean = Eq[A].neqv(lhs, rhs)
}
2 changes: 2 additions & 0 deletions tests/src/test/scala/cats/tests/SyntaxSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ object SyntaxSuite extends AllSyntaxBinCompat with AllInstances with AllSyntax {
val y = mock[A]
val b0: Boolean = x === y
val b1: Boolean = x =!= y
val b2: Boolean = x eqv y
val b3: Boolean = x neqv y
}

def testPartialOrder[A: PartialOrder]: Unit = {
Expand Down