【问题标题】:Why does json4s need a Scala compiler as a runtime dependency为什么 json4s 需要一个 Scala 编译器作为运行时依赖
【发布时间】:2014-06-27 08:00:04
【问题描述】:

我通过使用 json4s native 发现了这一点

    <dependency>
        <groupId>org.json4s</groupId>
        <artifactId>json4s-native_2.10</artifactId>
        <version>3.2.9</version>
    </dependency>

带来 scalap 和 scala-compiler 依赖项。

为什么需要它?

它会在运行时动态生成代码吗?

为什么它不使用在编译时执行此处理的宏?

【问题讨论】:

    标签: scala json4s


    【解决方案1】:

    json4s的人已经在this issue回复了我如下:

    因为我们需要读取字节码来找出有关 scala 原语的信息。这在 2.9 上比在 2.10 上更需要

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2019-01-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-06-09
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多