I will add to how crazy this is. The C standard has been very careful
to not break existing code. For example the C99 boolean is _Bool not
bool because C reserves _[A-Z]* for its own use. This means a valid C89
program is a valid C99 and C11 program. It Look like this is not true in
C++.

-Nathan

On Thu, Feb 25, 2016 at 09:52:49PM +0000, Jeff Squyres (jsquyres) wrote:
> > On Feb 25, 2016, at 3:39 PM, Paul Hargrove <phhargr...@lbl.gov> wrote:
> > 
> > A "bare" function name (without parens) is the address of the function, 
> > which can be converted to an int, long, etc.
> > So the "rank" identifier can validly refer to the function in this context.
> 
> I understand that there's logic behind this.  But it's still crazy to me that:
> 
> -----
> int foo(void) {
>   int rank;
>   printf("Value: %d", rank);
> }
> -----
> 
> is ambiguous.
> 
> -- 
> Jeff Squyres
> jsquy...@cisco.com
> For corporate legal information go to: 
> http://www.cisco.com/web/about/doing_business/legal/cri/
> 
> _______________________________________________
> devel mailing list
> de...@open-mpi.org
> Subscription: http://www.open-mpi.org/mailman/listinfo.cgi/devel
> Link to this post: 
> http://www.open-mpi.org/community/lists/devel/2016/02/18624.php

Attachment: pgpF_pXyKjjlg.pgp
Description: PGP signature

Reply via email to