comparison src/editfns.c @ 41062:07a4ff5f0909

(Fpropertize): Allow call with 1 arg.
author Richard M. Stallman <rms@gnu.org>
date Thu, 15 Nov 2001 00:34:42 +0000
parents fee88c193206
children af0215d05281
comparison
equal deleted inserted replaced
41061:9687641007d3 41062:07a4ff5f0909
3080 { 3080 {
3081 return current_message (); 3081 return current_message ();
3082 } 3082 }
3083 3083
3084 3084
3085 DEFUN ("propertize", Fpropertize, Spropertize, 3, MANY, 0, 3085 DEFUN ("propertize", Fpropertize, Spropertize, 1, MANY, 0,
3086 doc: /* Return a copy of STRING with text properties added. 3086 doc: /* Return a copy of STRING with text properties added.
3087 First argument is the string to copy. 3087 First argument is the string to copy.
3088 Remaining arguments form a sequence of PROPERTY VALUE pairs for text 3088 Remaining arguments form a sequence of PROPERTY VALUE pairs for text
3089 properties to add to the result. 3089 properties to add to the result.
3090 usage: (propertize STRING &rest PROPERTIES) */) 3090 usage: (propertize STRING &rest PROPERTIES) */)
3095 Lisp_Object properties, string; 3095 Lisp_Object properties, string;
3096 struct gcpro gcpro1, gcpro2; 3096 struct gcpro gcpro1, gcpro2;
3097 int i; 3097 int i;
3098 3098
3099 /* Number of args must be odd. */ 3099 /* Number of args must be odd. */
3100 if ((nargs & 1) == 0 || nargs < 3) 3100 if ((nargs & 1) == 0 || nargs < 1)
3101 error ("Wrong number of arguments"); 3101 error ("Wrong number of arguments");
3102 3102
3103 properties = string = Qnil; 3103 properties = string = Qnil;
3104 GCPRO2 (properties, string); 3104 GCPRO2 (properties, string);
3105 3105