Make reading of numbers locale-independent.
Fix incorrect rounding in some tests.
Fix locale-specific behaviour in serialisation of floats.