I was trying to increment a (void *) type variable, as shown below. However, I got compiling error message under Windows Visual C/C++ 2003. It doesn't seem to be a problem at Linux.
The particular operating system doesn't matter.
What matters is the compiler and whether the code is legal c++.
The code you give isn't right (and I don't believe that it compiled using a compiler on linux).