You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ scala -optimise -Yinline-warnings
Welcome to Scala version 2.11.2 (JavaHotSpot(TM) 64-BitServerVM, Java1.8.0_11).
Type in expressions to have them evaluated.
Type:help for more information.
scala>@inline deff(body: =>Unit) = body
f: (body: =>Unit)Unit
scala>defg() = f(println("hi"))
<console>:8:warning: Could not inline required method f because bytecode unavailable.
defg() = f(println("hi"))
^
<console>:8:warning: At the end of the day, could not inline @inline-marked method f
defg() = f(println("hi"))
^
g: ()Unit
and
$ scala -optimise -Yinline-warnings -Yrepl-class-based
Welcome to Scala version 2.11.2 (JavaHotSpot(TM) 64-BitServerVM, Java1.8.0_11).
Type in expressions to have them evaluated.
Type:help for more information.
scala>@inline deff(body: =>Unit) = body
f: (body: =>Unit)Unit
scala>defg() = f(println("hi"))
<console>:8:warning: At the end of the day, could not inline @inline-marked method f
defg() = f(println("hi"))
^
g: ()Unit
The text was updated successfully, but these errors were encountered:
$ scala -Dscala.repl.info -opt:inline-global -opt-warnings:_
Welcome to Scala 2.12.0 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_111).
Type in expressions for evaluation. Or try :help.
[info] started at Sat Nov 12 01:44:37 PST 2016
scala 2.12.0> <console>:11: warning: failed to determine if value should be inlined:
The method value()Lscala/tools/nsc/interpreter/IMain; could not be found in the class or any of its parents.
Note that class could not be found on the classpath.
val $intp = value
^
scala 2.12.0> @inline def f(body: => Unit) = body
f: (body: => Unit)Unit
scala 2.12.0> def g() = f(println("hi"))
<console>:12: warning: failed to determine if f should be inlined:
The method f(Lscala/Function0;)V could not be found in the class or any of its parents.
Note that class could not be found on the classpath.
def g() = f(println("hi"))
^
g: ()Unit
@SethTisue said:
I've changed the "Affects version" to just 2.12.0 since that's the only version of the issue that could plausibly receive a fix, giving the changeover of back ends.
and
The text was updated successfully, but these errors were encountered: