我收到一个错误
ScalaFiddle.scala:45: error: ambiguous implicit values:
both getter _ewriter in module class ScalaFiddle of type =>
json.this.Reads[ScalaFiddle.this.SportJSON]
and getter _jwriter in module class ScalaFiddle of type =>
json.this.Reads[ScalaFiddle.this.Score]
match expected type json.this.Reads[T]
val result: Soccer=Json.fromJson(t2).get
^
任何人都知道这意味着什么或有关阅读什么来解决的任何提示?
一般来说,我也尝试过 Circe 和 Spray(也没有运气),这些宏是否依赖于与 json 字段名称完全相同的字段名称?
谢谢!
有问题的代码:https : //scalafiddle.io/sf/BOUqhMz/0
编辑:Json 有问题,谢谢!https://pastebin.com/usScQWd7
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句