Floating point support and bug fixes in convert.

1. Lots of fixes, particularly with longer values.
2. Added support for floating point values.