From cd196f125640597cb91f3f66ae2608c6923044fa Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 30 Aug 2010 14:47:49 +0200 Subject: [PATCH] * src/marker.c (Fcopy_marker): Make the first arg optional. --- src/ChangeLog | 4 ++++ src/marker.c | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 4e4f96786d9..fe97d576b9c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2010-08-30 Stefan Monnier + + * marker.c (Fcopy_marker): Make the first arg optional. + 2010-08-30 Kenichi Handa * composite.c (composition_update_it): Fix computing of diff --git a/src/marker.c b/src/marker.c index 911d2e57706..b5ea80562df 100644 --- a/src/marker.c +++ b/src/marker.c @@ -806,16 +806,18 @@ marker_byte_position (Lisp_Object marker) return i; } -DEFUN ("copy-marker", Fcopy_marker, Scopy_marker, 1, 2, 0, +DEFUN ("copy-marker", Fcopy_marker, Scopy_marker, 0, 2, 0, doc: /* Return a new marker pointing at the same place as MARKER. If argument is a number, makes a new marker pointing at that position in the current buffer. +If MARKER is not specified, the new marker does not point anywhere. The optional argument TYPE specifies the insertion type of the new marker; see `marker-insertion-type'. */) (register Lisp_Object marker, Lisp_Object type) { register Lisp_Object new; + if (!NILP (marker)) CHECK_TYPE (INTEGERP (marker) || MARKERP (marker), Qinteger_or_marker_p, marker); new = Fmake_marker (); -- 2.39.2