Scala: keyword as package name

前端 未结 2 458
孤街浪徒
孤街浪徒 2021-01-07 19:47

I\'m trying to use a Java library (no source code available) which defines some xxx.xxx.object package. Scala complains about the presence of \"object\" in

2条回答
  •  难免孤独
    2021-01-07 20:49

    Wrapping the object in a ` (the quote next to 1) should work.

    xxx.xxx.`object` 
    

提交回复
热议问题