Skip to content

Commit 0427731

Browse files
committed
Add regression test
1 parent 50545a7 commit 0427731

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import scala.quoted.*
2+
3+
inline def foo[U](u: U): U = ${ fooImpl[U]('u) }
4+
5+
def fooImpl[U: Type](u: Expr[U])(using Quotes): Expr[U] = '{
6+
def f[T](x: T): T = ${ identity('{ x: T }) }
7+
f[U]($u)
8+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
def test =
2+
foo(1)
3+
foo("abc")

0 commit comments

Comments
 (0)