- About Scala
- In the Enterprise
- Scala Community
- Language Research
- In the Press
- The Scala Team
- Scala's Prehistory
- Contact Us
- Learning Scala
- Tour of Scala
- Scala API
- Setup & Getting Started
- Programming Guides
- Other Guides
- Code Examples
- Scala Developers
Re: package naming and implicit conversion
>>>>> "Russ" == Russ Paielli writes:
Russ> Does it make sense to label an entire file with a package name
Russ> that is the same as the main class in the file, as in
Russ> package MoonRocket class MoonRocket() ....
Russ> or is that just asking for trouble?
No one does this. What problem are you trying to solve with this?
Probably we can suggest a different solution.
Russ> As for implicit conversions, I am flummoxed. I am reading page
Russ> 441 of the Odersky book, the section Rules for Implicits. It says
Russ> plain as day that if you put an implicit definition in the
Russ> companion object, "The compiler will find such an associated
Russ> conversion every time it needs to convert ..." But I am
Russ> discovering otherwise. What gives? Is the book lying?
We'll need to see your actual code.