At a first sight the idea of having a standard fromString seems good. I think Haskell has something similar, the standard Read typeclass: http://hackage.haskell.org/packages/archive/base/latest/doc/html/Prelude.html#t:Read Bye, bearophile