[Carpet] Re: CarpetLib compile dies on lemieux

Erik Schnetter schnetter at cct.lsu.edu
Sun Nov 13 18:58:54 CET 2005


On Nov 12, 2005, at 22:56:40, Steve White wrote:
> One other point:  these alphabetic operators blow a very nice  
> property of
> C:  Outside of string literals, whitespace was disregarded.  With  
> these
> operators, whitespace is important.  But C++ had already lost that  
> nice C
> property with template notation.  Sometimes the things we think are  
> most
> precious are lost.

Consider "int x" vs. "intx" or "long long", which are syntax errors  
without white space.  Of course, templates have the ">>" problem, but  
there is also "--5", which is not "+5", although "- -5" is.  And  
don't get me started about ending a line with backslash-space.  Of  
course, "white space is disregarded" is also not true for "//" style  
comments and preprocessor commands, which extend to the end of the line.

Only fixed form Fortran is independent of white space, for better or  
worse.  Since humans generally use white space to parse source code,  
I consider it a good idea if compilers also do so.  It is dangerous  
that humans rely on indentation to read code, while compilers match  
parentheses.  I wonder why no C or C++ compiler even implements  
optional warnings about suspicious indentation.

Can you write a standard conforming one-line programme in C that  
prints "Hello, World!"?  You can do that in Fortran...

It's good to know that there are compiler switches on Lemieux to make  
the C++ compiler accept these keywords.  If there is a platform where  
this is not possible, we will have to autoconfigure them.

-erik

-- 
Erik Schnetter <schnetter at cct.lsu.edu>

My email is as private as my paper mail.  I therefore support encrypting
and signing email messages.  Get my PGP key from www.keyserver.net.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 186 bytes
Desc: This is a digitally signed message part
Url : /archives/developers/attachments/20051113/a8371724/attachment.pgp 


More information about the developers mailing list