Closed
Description
Compiler version
3.0.2
Minimized code
(transparent) inline def f(x: Int) = inline x match
case 1 => 1
case _ => 0
@main def m =
val v = 1
println(f(v))
Output
0
Expectation
Give the same output as (namely 1)
inline def f(x: Int) = x match
case 1 => 1
case _ => 0
and if not, be documented in the "Inline Matches" section of https://docs.scala-lang.org/scala3/reference/metaprogramming/inline.html.
(Note that this does work when v
has singleton type 1
)