Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The pointers itself don't seem to be the problem. Rather, it's C's strange syntax which tries to mimick a variable's use in its declaration. I.e. "int * * p;" doesn't mean "p is a pointer to a pointer to an int", but it means "* * p is an int". And so goes away any contradiction.


Huh? it means both.


Yes it means both. It is just a hint how to read / write it: Don't make up some type syntax, but use the variable usage syntax and what's left is primitive types.

See http://cm.bell-labs.com/cm/cs/who/dmr/chist.html for history.

Sadly, C++ destroys that arguably strange consistency by its reference type declarations.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: