Closed
Description
Compiler version
a7f00e2 (main)
Minimized code
//> using option -Xprint:inlining
inline def twice(inline thunk: =>Unit): Unit =
thunk
thunk
inline def pipe(inline t: =>Unit, inline f: (=>Unit) => Unit): Unit = f(t)
@main def test =
pipe(println("foo"), twice)
Output
@main def test: Unit =
{
val thunk: Unit = println("foo")
{
thunk
thunk
}:Unit
}:Unit
Expectation
@main def test: Unit =
{
def thunk: Unit = println("foo")
{
thunk
thunk
}:Unit
}:Unit