On Jul 13, 2:47 am, Yorick Peterse <[email protected]> wrote:
> Jeremy,
>
> While I'm all for this fix, especially since I can't think of any issues
> with to_i() and to_f() (I might just not know about them),
'a'.to_i = 0
'a'.to_f = 0.0
> I think it's a
> good idea to provide an
> extension that makes the code backwards compatible just like you said. This
> would give people the time to either update their code or realize newer
> versions of
> Sequel just aren't going to work for certain applications (sometimes
> updating legacy code just isn't going to work). Just out of curiosity, what
> was your initial
> motivation for going with Kernel#Integer and Kernel#Float rather than using
> to_f() and to_i()?
Integer('a') # raises ArgumentError
Float('a') # raises ArgumentError
Note that the looser_typecasting extension makes the database use to_i
and to_f.
Jeremy
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sequel-talk?hl=en.