This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Why does gcc4 dislike this code?
Brian Dessent wrote:
walt wrote:
*((unsigned long int *) tmp)++ = *((unsigned long int *) b1)++;
error: invalid lvalue in increment
The lvalue cast was a nonstandard gcc extension that was removed in 3.4;
in other words this is not valid standard C/C++.
http://gcc.gnu.org/gcc-3.4/changes.html
Wow, that was fast, thanks. I'm quite sure I'd never write code
like that in the first place, mostly because it would never occur
to me to try it. If you had to fix that code, how would you do it?