Skip to content

Commit 5ab37f2

Browse files
nicolasstuckigriggt
authored andcommitted
Update reflect param clauses API
(cherry picked from commit 69e29ed) (cherry picked from commit 25fdf1b)
1 parent db0c31e commit 5ab37f2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

dotty/scalactic/src/main/scala/org/scalactic/BooleanMacro.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,14 +70,14 @@ object BooleanMacro {
7070
def unapply(t: Term): Option[Term] = t match {
7171
case Block(
7272
ddef @
73-
DefDef(_, (ValDef(name, _, _) :: Nil) :: Nil, _,
73+
DefDef(_, TermParamClause(param :: Nil) :: Nil, _,
7474
Some(Apply(Select(lhs, "=="), rhs :: Nil))
7575
) :: Nil,
7676
clos
7777
) if (clos.tpe.isFunctionType) => // walkaround: https://github.com/lampepfl/dotty/issues/6720
7878
(lhs, rhs) match {
79-
case (Ident(refName), _) if refName == name => Some(rhs)
80-
case (_, Ident(refName)) if refName == name => Some(lhs)
79+
case (Ident(refName), _) if refName == param.name => Some(rhs)
80+
case (_, Ident(refName)) if refName == param.name => Some(lhs)
8181
case _ => None
8282
}
8383
case _ => None

0 commit comments

Comments
 (0)