tags:

views:

51

answers:

1

It seems to me that all of a sudden Vim doesn't recognize the decimal point anymore.

For example, if I do a

: echo 22.0/3.0

then I receive a

2200

This is probably because Vim sees the dot as a string concatenator and so calculates 22 . (0/3) . 0 which is 22 . 0 . 0 which then is 2200.

I can confirm this suspicion by doing a :echo 3.9 and when I receive a 39.

I am pretty sure that I had this working correctly (whereas correctly means: as I expected). So, have I changed some setting or something?

Thanks / Rene

A: 

This works in Vim 7.2, gVim as well. You explicitly have to surround the numbers with quotes to get the result you posted. I suggest you upgrade your Vim.

Pierre-Antoine LaFayette
Sure enought, I had this occurence on another computer with still Vim 7.1 installed.
René Nyffenegger