Can java run a compiled scala code?

后端 未结 4 1018
囚心锁ツ
囚心锁ツ 2020-12-10 10:16

Can command java run a compiled scala code? If so, why do we have an exclusive command scala?

4条回答
  •  误落风尘
    2020-12-10 10:38

    You can run byte code generated by Scala if you include all necessary runtime libs for Scala (scala-library.jar, scala-swing.jar ...) in the classpath. The scala command does this automatically, and supports Scala specific command line arguments.

提交回复
热议问题