I know this matches your hierarchy, but what about placing all your personal methods in
private trait Y {
Otherwise, you can always simulate a namespace:
object SuperHorribleLongName { object SHLN { //Dummy alias trait X { private[SHLN] def internalGaga() : Unit } } type X = SHLN.X //Lift into main object }
This is not satisfactory, since the SHLN is visible, and its private
rotation prevents the rise of X. And this is messy.
So, include the problem inside / outside:
private object SHLN { trait X { private[SHLN] def internalGaga() : Unit } }
source share