(command-line-1): Pass arg to other-window.
[bpt/emacs.git] / lisp / sort.el
index 2d56aee..0ee9012 100644 (file)
 ;; along with GNU Emacs; see the file COPYING.  If not, write to
 ;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
 
+;;; Commentary:
+
+;;; This package provides the sorting facilities documented in the Emacs
+;;; user's manual.
+
 ;;; Code:
 
 (defun sort-subr (reverse nextrecfun endrecfun &optional startkeyfun endkeyfun)
@@ -239,12 +244,13 @@ Fields are separated by whitespace and numbered from 1 up.
 Specified field must contain a number in each line of the region.
 With a negative arg, sorts by the ARGth field counted from the right.
 Called from a program, there are three arguments:
-FIELD, BEG and END.  BEG and END specify region to sort."
+FIELD, BEG and END.  BEG and END specify region to sort.
+If you want to sort floating-point numbers, try `sort-float-fields'."
   (interactive "p\nr")
   (sort-fields-1 field beg end
                 (function (lambda ()
                             (sort-skip-fields (1- field))
-                            (string-to-int
+                            (string-to-number
                              (buffer-substring
                                (point)
                                (save-excursion
@@ -254,6 +260,7 @@ FIELD, BEG and END.  BEG and END specify region to sort."
                                  (point))))))
                 nil))
 
+;;;###autoload
 (defun sort-float-fields (field beg end)
   "Sort lines in region numerically by the ARGth field of each line.
 Fields are separated by whitespace and numbered from 1 up.  Specified field