Mercurial > emacs
comparison src/fns.c @ 56358:97e94a98c666
(Fclear_string): Signal an error if STRING is not a string.
author | John Paul Wallington <jpw@pobox.com> |
---|---|
date | Tue, 06 Jul 2004 05:07:20 +0000 |
parents | 98133cccc0cc |
children | 1f6748b338da |
comparison
equal
deleted
inserted
replaced
56357:ca58dab79be1 | 56358:97e94a98c666 |
---|---|
2368 doc: /* Clear the contents of STRING. | 2368 doc: /* Clear the contents of STRING. |
2369 This makes STRING unibyte and may change its length. */) | 2369 This makes STRING unibyte and may change its length. */) |
2370 (string) | 2370 (string) |
2371 Lisp_Object string; | 2371 Lisp_Object string; |
2372 { | 2372 { |
2373 CHECK_STRING (string); | |
2373 int len = SBYTES (string); | 2374 int len = SBYTES (string); |
2374 bzero (SDATA (string), len); | 2375 bzero (SDATA (string), len); |
2375 STRING_SET_CHARS (string, len); | 2376 STRING_SET_CHARS (string, len); |
2376 STRING_SET_UNIBYTE (string); | 2377 STRING_SET_UNIBYTE (string); |
2377 return Qnil; | 2378 return Qnil; |