motivation:
scala-native uses packages names, such as scala.scalanative.native:
https://github.com/scala-native/scala-native/tree/master/nativelib/src/main/scala/scala/scalanative/native
which contains java reserved keywords, such as native,
which results in various problems in Scala IDE,
including inability to view class files from such packages
a solution could be just to rename such packages,
i.e. native -> nativelib, instead of fighting various IDEs
the word native itself is heavily overused and overloaded
perhaps scala.scalanative.clang or scala.scalanative.interop are more descriptive terms
The scala.scalanative.native is intentional and mimicks scala.scalajs.js. It's our main entry point to the user-facing interoperability APIs. Changing it will break every single Scala Native project that interacts with C libraries. It's a bit too late for this kind of change.
:-) then proper mapping should be:
scala.scalajs.js -> scala.scalan.n
the sooner the break the better:
@densh I guess @Andrei-Pozolotin is technically correct about package naming restrictions. I'm not sure a change now would be the worst thing but I haven't published anything yet. I would think most of the user facing libs are Scala cross projects. We could look on scaladex https://index.scala-lang.org/search?q=*&targetTypes=Native for those with native components.
https://docs.oracle.com/javase/tutorial/java/package/namingpkgs.html
https://docs.oracle.com/javase/tutorial/java/nutsandbolts/_keywords.html
more native + Scala IDE fun:
import scala.scalanative.native.time._
Error: object time is not a member of package scala.scalanative.native Note: class time exists, but it has no companion object.
A better name alternative: unsafe. Short. Clear that you can cut yourself. Mirrors what other languages are calling it.
thank you
Most helpful comment
A better name alternative:
unsafe. Short. Clear that you can cut yourself. Mirrors what other languages are calling it.