As to the sorted text, you generate a ramp of values so what were you expecting to see?
Somehow I managed to reverse concatenated string and *(type *) &x in my head
NO wonder I could not duplicate at home
At least I have line feeds
At the moment, there is not yet a recommended workaround documented in the CAR.