PROPOSAL: Auto-assignment Parameters (original) (raw)
Mark Mahieu markmahieu at googlemail.com
Thu Mar 26 17:07:40 PDT 2009
- Previous message: PROPOSAL: Auto-assignment Parameters
- Next message: PROPOSAL: Auto-assignment Parameters
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
2009/3/26 Marek KozieĊ <develop4lasu at gmail.com>
class Some{ private String name; public this setName (String this.name){}; public this.name getName(){}; }
Leaving to one side the idea of returning 'this' from setName, yes auto-assignment parameters could easily be made to work on all non-abstract instance methods.
As you suggest, this could be extended even further to return values, but one of the questions that raises is whether it's acceptable to omit the type, as you've done in your example (imagine what it would look like in a much bigger class with many more methods).
Mark
- Previous message: PROPOSAL: Auto-assignment Parameters
- Next message: PROPOSAL: Auto-assignment Parameters
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]