This was brought up in the Kara group last week. The problem is that, for a large-ish framework like Kara, the code is broken up into dozens of packages. For any given file in a project that uses Kara, you may need to import 5-10 of these packages. For the most part, the IDE will do a good job of telling which ones are needed, but there are some cases where it won't (like extension operator overloads).
The suggestion was to simply flatten the Kara package hierarchy into one package that you can import into every file and be done. While this would make life easier for the end-user, it seems like it would make it more difficult to maintain the framework and would also break the folder-based package naming assumption.
It seems like a good middle ground would be to add a recursive import statement into Kotlin, such that the end-user can specify something like:
and the compiler would know to import all packages starting with ‘kara.’. So my question is: does this seem like a reasonable request or a difficult one to implement? Are there any hidden gotchas for an implementation like this (other than the obvious need to ensure there are no class/function naming collisions in all of the child packages)?