C's syntax (was Re: Python Formatted C Converter (PfCC))
Daniel Berlin
dberlin at redhat.com
Tue Oct 24 00:37:20 EDT 2000
Erik Max Francis <max at alcyone.com> writes:
> Rainer Deyke wrote:
>
> > int (*a)[5], *(b[5]);
> >
> > It looks like 'a' is an array of pointers and 'b' is a pointer to an
> > array,
> > but the opposite is the case.
>
> Makes perfect sense, if you that you read C declarations from the inside
> out.
>
> C is not a trivial language, so the rules are not trivial. If you have
> sloppy thinking or are not familiar with the details of the language,
> you will get yourself into trouble with a non-trivial language. But
> then that's true of a trivial language as well.
Sloppy thinking?
You mean, sorta like how
"hello"[4] == 4["hello"] ?
That kind of sloppy thinking?
Or is that a feature?
--Dan
More information about the Python-list
mailing list