[eluser]xwero[/eluser]
So we have four solutions:
- a object/variable white list for the models.
pro : flexible
con : configuration
- a namespace for controller connected objects/variables
pro : no collisions with local variables
con : additional typing (CI->)
- don't attach the instance, helper syntax
pro : only code change to core is removing the attaching of the controller objects/variables
con : more code in the models
- don't attach the instance, kohana syntax
pro : controller variables/objects stay in controller scope
con : will require ugly php4 hack
If we look at the resources, i don't know if it really matters, the namespace solution is as wastefull as the current solution or even a bit more. The white list is a little less wastefull and the don't attaching solutions are the most resource friendly.
If we look at the backwards compatibility the white list solution is the best way to go as it requires no changes in the current models code.