I want to store a 4-byte int in a char array... such that the first 4 locations of the char array are the 4 bytes of the int.
Then, I want to pull the int back out o
You can also use placement new for this:
void foo (int i) { char * c = new (&i) char[sizeof(i)]; }