We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ab58c2d commit dec41d1Copy full SHA for dec41d1
tests/pos/i4380a.scala
@@ -0,0 +1,23 @@
1
+import scala.quoted._
2
+
3
+object Test {
4
5
+ trait Producer[A] { self =>
6
+ def step(k: (A => Expr[Unit])): Expr[Unit]
7
+ }
8
9
+ trait Foo[A]
10
+ case class Bar[A, B](producer: Producer[B], nestedf: B => Expr[Unit]) extends Foo[A]
11
12
+ def meth[A](stream: Foo[Expr[A]]): Producer[Expr[A]] = {
13
+ stream match {
14
+ case Bar(producer, nestedf) => {
15
+ new Producer[Expr[A]] {
16
+ def step(k: Expr[A] => Expr[Unit]): Expr[Unit] = '{
17
+ val adv: Unit => Unit = { _ => ~producer.step((el) => nestedf(el))}
18
19
20
21
22
23
+}
tests/pos/i4380b.scala
@@ -0,0 +1,8 @@
+ def step(k: (String => Expr[Unit])): Expr[Unit] = '()
+ def meth(): Unit = '{
+ (i: Int) => ~step(el => '() )
0 commit comments