Steve Simmons wrote:
> IMHO the code
>
> $a = '3.14'; # from reading a file
> $b = '3.1400'; # from user input
> if ($a == $b) { ... }
>
> should see the two args being tested in numeric context, do the numeric
> casting, get floats, and do a floating compare. Durned if I know what it
> does now.
I'd like to see every number bundled with a "precision" attribute. It's
a holdover from when I was heavily into chemistry. Computers often give
us more precision than is warrented in a given situation, and a language
that would know it was doing GIGO and stop would be a good thing.
With strong types, I can go ahead and write myself a bigfloat::precise
type and use it. Sometimes the line between "attribute" and "value" is
completely semantic. But that doesn't mean it isn't there.
--
David Nicol 816.235.1187 [EMAIL PROTECTED]
Yum, sidewalk eggs!
- Re: ... as a term Damian Conway
- Re: ... as a term Larry Wall
- Re: ... as a term Jonathan Scott Duff
- Re: ... as a term John Porter
- Re: ... as a term Larry Wall
- Re: ... as a term John Porter
- Re: ... as a term Jonathan Scott Duff
- Re: ... as a term John Porter
- Re: Do we really need eq? Steve Simmons
- Re: Do we really need eq? John Porter
- Re: Do we really need eq? David L. Nicol
- Re: Do we really need eq? Peter Scott
- Re: Do we really need eq? Tom Christiansen
- Re: Do we really need eq? Andy Dougherty
- attributes definable as well as value... David L. Nicol
- Re: Do we really need eq? Dan Sugalski
- RE: Do we really need eq? Lipscomb, Al
- Re: Do we really need eq? Nathan Wiger
- RE: Do we really need eq? Fisher Mark
- Re: Do we really need eq? David L. Nicol
- Re: Do we really need eq? Dan Sugalski
