Pointers count bytes, so to indicate the next byte you will need to change the value of the pointer to 1. Arithmetic of the pointer, however, counts the objects that the pointer points to, and incrementing the pointer increases its value by the size of its type of pointer. If you want to point to bytes, use the char pointer, since char is size 1 by definition, and the arithmetic pointer on char pointers allows you to point to bytes:
T * p = get_pointer(); char * cp = reinterpret_cast<char*>(p); cp += 16;
Cast pointers to char types do not represent ping forms and are explicitly permitted by the standard. However, you should not use the resulting pointer to access any objects that are not actually located at this address.
source share