Detect precision from a Measurement value if it provided as a string

String literals have the ability to contain the precision for a
measurement. Unless a precision is explicitly defined, the number of
digits is the string is set as the precision. This is a flawed
implementation as '1000' would be treated as precision 4, which it is
actually 1.
Fix toString for mangnitudes