[M3devel] whitespace rationale?

Tony Hosking hosking at cs.purdue.edu
Fri Apr 18 18:02:04 CEST 2008


Purely a matter of style.  I generally don't put the space for calls:

	EVAL f();

but I do for declarations:

	PROCEDURE f () = ...

just so that when I want to search for a local declaration I can  
easily do that with a text search for "f ()".  Just my 2 cents.

However, when editing code in any one style, I tend to preserve the  
style.

On Apr 18, 2008, at 11:01 AM, Jay wrote:

> Does anyone know of a reason to put a space between a function and  
> the paren to start its call?
> Other than "When in Rome"?
>
> I've long not put that in, but I see a fair amount of code that  
> does, and a fair amount of code that I didn't write that doesn't  
> (e.g. sysutils).
> Seems to be all over the place, but a lot of Modula-3 code puts it  
> in (not that I have seen much Modula-3 code in the world...but...)
>
> Similarly for array indexing array [index] vs. array[index].
>
> (Not to mention if (expr) and not if ( expr ). Modula-3 (and  
> Python!) doesn't require the parens so it comes up less often.)
>
> I always like to know why..
>
>  - Jay
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20080418/4d779745/attachment-0002.html>


More information about the M3devel mailing list