On Fri, 21 Sep 2001 09:12:11 +0100, Chris Douce <[EMAIL PROTECTED]> wrote:

> 
> About a year ago I was embroiled in an increasingly heated debate about
> bracketing, namely where to place a bracket after a keyword.  In one case, a
> bracket was placed immediately after a keyword, i.e:
> 
>     if(foo == bar)
> 
> in another case, the line would be:
> 
>     if (foo == bar)
> 
> Where a space would be present after the keyword.  It occurred to me that
> there could potentially be a recognition penalty for the keyword in the
> first case.
> 
> My question is, does anybody know of any psychology of programming or
> related research that can help to solve this dilemma?  I can't think of
> anything off the top of my head.

The key is to always put the parenthesis before the keyword and the space
after:

        (if (eq foo bar) ... )

:-j

... or don't forget to review your assumptions about syntax in the first
place.

FTR I'd write the original infix as:

        if ( foo == bar )

ie with two more spaces.

__Jason


- Automatic footer for [EMAIL PROTECTED] ----------------------------------
To unsubscribe from this list, mail [EMAIL PROTECTED]  unsubscribe discuss
To join the announcements list, mail [EMAIL PROTECTED] subscribe announce
To receive a help file, mail [EMAIL PROTECTED]         help
This list is archived at http://www.mail-archive.com/discuss%40ppig.org/
If you have any problems or questions, please mail [EMAIL PROTECTED]

Reply via email to