Should we really be throwing an exception for this?  This function is used by the GUI to validate text entered, and the user is going to try to type in all sorts of garbage.  Is it really an exceptional case?  Maybe it could be restructured to return a boolean.