patch 7.4.1143
Problem: Can't sort on floating point numbers.
Solution: Add the "f" flag to ":sort". (Alex Jakushev) Also add the "f"
flag to sort().
diff --git a/runtime/doc/change.txt b/runtime/doc/change.txt
index 6dd20ad..ac1b8b6 100644
--- a/runtime/doc/change.txt
+++ b/runtime/doc/change.txt
@@ -1,4 +1,4 @@
-*change.txt* For Vim version 7.4. Last change: 2016 Jan 02
+*change.txt* For Vim version 7.4. Last change: 2016 Jan 19
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1745,7 +1745,7 @@
found here: |sort()|, |uniq()|.
*:sor* *:sort*
-:[range]sor[t][!] [i][u][r][n][x][o][b] [/{pattern}/]
+:[range]sor[t][!] [b][f][i][n][o][r][u][x] [/{pattern}/]
Sort lines in [range]. When no range is given all
lines are sorted.
@@ -1753,10 +1753,18 @@
With [i] case is ignored.
+ Options [n][f][x][o][b] are mutually exclusive.
+
With [n] sorting is done on the first decimal number
in the line (after or inside a {pattern} match).
One leading '-' is included in the number.
+ With [f] sorting is done on the Float in the line.
+ The value of Float is determined similar to passing
+ the text (after or inside a {pattern} match) to
+ str2float() function. This option is available only
+ if Vim was compiled with Floating point support.
+
With [x] sorting is done on the first hexadecimal
number in the line (after or inside a {pattern}
match). A leading "0x" or "0X" is ignored.
@@ -1768,10 +1776,10 @@
With [b] sorting is done on the first binary number in
the line (after or inside a {pattern} match).
- With [u] only keep the first of a sequence of
- identical lines (ignoring case when [i] is used).
- Without this flag, a sequence of identical lines
- will be kept in their original order.
+ With [u] (u stands for unique) only keep the first of
+ a sequence of identical lines (ignoring case when [i]
+ is used). Without this flag, a sequence of identical
+ lines will be kept in their original order.
Note that leading and trailing white space may cause
lines to be different.