Re: Consistent argument naming

Emiliano <[email protected]>
Newsgroups gmane.comp.java.xwt.widgets
Message-ID <[email protected]>
On Mon, May 19, 2003 at 02:42:15PM -0000, Charles Goodwin wrote:
> Here's a thought.
> 
> _trap = function( v ) { ... }
> 
> Should we always use 'v'?
> 
> eg you'll typically find:
> _focused = function( f ) { ... }
> _selected = function( s ) { ... }
> 
> If v was _always_ used then maybe it would add to the readability of the
> code.  The only issue you'd have would be with:
> 
> _trap1 = function( v ) {
>     _trap2 = function( w ) { ... }
> }
> 
> In which case you could use 'w' as you get deeper, and 'x' if you go one
> deeper and so on.
> 
> Is this a good or bad idea?

+1. I like consistency.

Emile
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.