On 09/04/08 00:43, Antony Scriven wrote:
> On 08/04/2008, Bram Moolenaar<[EMAIL PROTECTED]>  wrote:
>
>   >  I have been preparing a talk for the upcoming FISL
>   >  conference in Brazil:
>   >  http://fisl.softwarelivre.org/9.0/www/
>   >
>   >  One of the items I planned to discuss is why Vim has no
>   >  floating point support.  Well, this turned into actually
>   >  implementing it.
>   >
>   >  The main problem with floating point is that the usual
>   >  notation already has a meaning:
>   >
>   >         echo 123.456
>   >            123456
>   >
>   >  [...]
>
> How many people actually do that? Should they be doing that?
> IMHO I'd force people to use whitespace for concatenation in
> this case (i.e.  123 . 456) and have 123.456 be a floating
> point number. That's how Perl works, for example. --Antony

I always use spaces around the concatenation operator, but I've seen 
many people using it with no spaces, and as you know, in Vim upward 
compatibility is primordial.

This said, a quick glance at the code shows that it seems to use only a 
doubleword for floats -- doesn't the C language support a native "float" 
type (or even "long float" or something?), which would map to the IEEE 
datatypes used by e.g. the ix87 math coprocessor? If the hardware 
supports 10^-308 to 10^308, I wouldn't expect ":echo &1.e-100" to return 
zero.


Best regards,
Tony.
-- 
Sooner or later, generals will own you.

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui