What does *++x mean when x is a pointer to an int?
Are *(x++) and *(++x) the same?
What does *++x mean when x is a pointer to an int?
Are *(x++) and *(++x) the same?
*(x++) will increment x (make it point to the next integer in line) after dereferencing, while *(++x) will increment x before.
So the parentheses don't do anything?
You mean between *(x++) and *x++? Those are the same. The parentheses are redundant in *++x, since there's no way to interpret that other than pre-increment x, then dereference.
I mean between *(x++) and *(++x).
My homepage
Advice: Take only as directed - If symptoms persist, please see your debugger
Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"