Mercurial > emacs
comparison lisp/international/mule.el @ 22302:fb2d8c0920c6
(coding-system-mnemonic): Don't crash if arg is nil.
author | Karl Heuer <kwzh@gnu.org> |
---|---|
date | Mon, 01 Jun 1998 03:01:30 +0000 |
parents | e7ac7f644152 |
children | e1d07ef2af10 |
comparison
equal
deleted
inserted
replaced
22301:80bfa3fcb7fb | 22302:fb2d8c0920c6 |
---|---|
362 of CODING-SYSTEM. See the function `make-coding-system' for more detail." | 362 of CODING-SYSTEM. See the function `make-coding-system' for more detail." |
363 (aref (coding-system-spec coding-system) coding-spec-type-idx)) | 363 (aref (coding-system-spec coding-system) coding-spec-type-idx)) |
364 | 364 |
365 (defun coding-system-mnemonic (coding-system) | 365 (defun coding-system-mnemonic (coding-system) |
366 "Return the mnemonic character of CODING-SYSTEM. | 366 "Return the mnemonic character of CODING-SYSTEM. |
367 A mnemonic character of a coding system is used in mode line | 367 The mnemonic character of a coding system is used in mode line |
368 to indicate the coding system." | 368 to indicate the coding system. If the arg is nil, return ?-." |
369 (or (aref (coding-system-spec coding-system) coding-spec-mnemonic-idx) | 369 (let ((spec (coding-system-spec coding-system))) |
370 ?-)) | 370 (if spec (aref spec coding-spec-mnemonic-idx) ?-))) |
371 | 371 |
372 (defun coding-system-doc-string (coding-system) | 372 (defun coding-system-doc-string (coding-system) |
373 "Return the documentation string for CODING-SYSTEM." | 373 "Return the documentation string for CODING-SYSTEM." |
374 (aref (coding-system-spec coding-system) coding-spec-doc-string-idx)) | 374 (aref (coding-system-spec coding-system) coding-spec-doc-string-idx)) |
375 | 375 |