Fix bad ToString algorithm

My ignorance was uncovered by Waldo in #jslang on irc.mozilla.org; thanks Waldo!
Version 1.8.3