I never understood the reasoning behind this, is it that "the asterisk is part of the type, so we group it that way"?
That misses the point of the C declaration syntax: you write an expression that when used on its own will recover the basic type. So the asterisk goes with the symbol name, because that's how you dereference a pointer.
Further, it doesn't work if you want to declare more than one pointer like so:
That misses the point of the C declaration syntax: you write an expression that when used on its own will recover the basic type. So the asterisk goes with the symbol name, because that's how you dereference a pointer.
Further, it doesn't work if you want to declare more than one pointer like so: