Skip to content

Commit 1c85471

Browse files
nicolasstuckimichelou
authored andcommitted
Add regression test
1 parent 065aa8c commit 1c85471

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

tests/pos-macros/i11782.scala

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import scala.quoted._
2+
3+
trait X[A] { def x(a: A): Boolean }
4+
5+
def hmm[A](using Quotes, Type[A]): Expr[Unit] = {
6+
def sadFace(f: (Expr[A]) => Expr[Boolean]): Expr[X[A]] = '{
7+
new X[A] {
8+
override def x(a: A) = ${f('a)}
9+
}
10+
}
11+
'{()}
12+
}

0 commit comments

Comments
 (0)