Technically speaking, I'm aware of the fact that you can't dereference a void pointer.
I decided to play around with pointers (I've been out of practice for a while) and I noticed something odd when I viewed the output of the following program:
The lines of code that print the "address of i" and the "vPtr to i" yield the same address. Now the thing that got me thinking was even though vPtr is a void pointer and can't be dereferenced, it can still access the memory address that holds the value of i. Wouldn't that mean that there would be some way to derive the value stored at that address though the void pointer? I had asked someone else about this and they told me that you'd have to get the actual byte size and you could infer the value from that.
using namespace std;
int main(int argc, char** argv)
int i = 10;
cout << "Address of i " << &i << endl;
void *vPtr = &i;
cout << "Address of vPtr " << &vPtr << endl;
cout << "vPtr to i " << vPtr << endl;