Allow int values for double/float fields (fixes #4)