Since the qualms expressed on this topic had to do with converting strings to integers, I installed into master the noncontroversial part affecting conversion of integers to strings (see attached patch; it also fixes some minor glitches in the previous proposal). I'll think about the string-to-integer conversion a bit more and propose an updated patch for that.