Non-lossy string conversion