If you use a string stream to convert an integer to text, you're going to get a textual representation of the digits according to your locale. If the conversion were from 1 to ASCII, for instance, you would get '1' (0x31), not SOH (0x01).