emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/src fns.c


From: Chong Yidong
Subject: [Emacs-diffs] emacs/src fns.c
Date: Mon, 19 Jan 2009 15:13:31 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Chong Yidong <cyd>      09/01/19 15:13:31

Modified files:
        src            : fns.c 

Log message:
        (Fsubstring): Doc fix.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/src/fns.c?cvsroot=emacs&r1=1.454&r2=1.455

Patches:
Index: fns.c
===================================================================
RCS file: /sources/emacs/emacs/src/fns.c,v
retrieving revision 1.454
retrieving revision 1.455
diff -u -b -r1.454 -r1.455
--- fns.c       8 Jan 2009 03:15:38 -0000       1.454
+++ fns.c       19 Jan 2009 15:13:31 -0000      1.455
@@ -1183,11 +1183,16 @@
 }
 
 DEFUN ("substring", Fsubstring, Ssubstring, 2, 3, 0,
-       doc: /* Return a substring of STRING, starting at index FROM and ending 
before TO.
-TO may be nil or omitted; then the substring runs to the end of STRING.
-FROM and TO start at 0.  If either is negative, it counts from the end.
-
-This function allows vectors as well as strings.  */)
+       doc: /* Return a new string whose contents are a substring of STRING.
+The returned string consists of the characters between index FROM
+\(inclusive) and index TO (exclusive) of STRING.  FROM and TO are
+zero-indexed: 0 means the first character of STRING.  Negative values
+are counted from the end of STRING.  If TO is nil, the substring runs
+to the end of STRING.
+
+The STRING argument may also be a vector.  In that case, the return
+value is a new vector that contains the elements between index FROM
+\(inclusive) and index TO (exclusive) of that vector argument.  */)
      (string, from, to)
      Lisp_Object string;
      register Lisp_Object from, to;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]