all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* define-generic-mode: unexpected handling of comment-end
@ 2004-11-24  9:46 Kai Grossjohann
  2004-11-24 14:03 ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: Kai Grossjohann @ 2004-11-24  9:46 UTC (permalink / raw)


It seems that it doesn't work to specify ("# " . "") for comments:

Debugger entered--Lisp error: (args-out-of-range "" 0)
  generic-mode-set-comments((("# " . "")))
  generic-mode-internal(baselib-config-mode (("# " . "")) ("include") nil nil)
  baselib-config-mode()
  set-auto-mode-0(baselib-config-mode nil)
  set-auto-mode()
  normal-mode(t)
  after-find-file(nil nil t t nil)
  revert-buffer(t)
  call-interactively(revert-buffer)

Specifying ("# " . nil) instead works as I intended ("# " . "") to work.

Shouldn't the documentation say that comment-end is handled specially?

Here's the code:

(define-generic-mode
  'baselib-config-mode                  ;name
  '(("# " . nil))                       ;comment-list
  '("include")                          ;keyword-list
  nil                                   ;font-lock-list
  '("\\.cfg\\'")                        ;auto-mode-list
  nil                                   ;function-list
  "Mode for editing baselib config files.")

Kai

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2004-11-25  9:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-24  9:46 define-generic-mode: unexpected handling of comment-end Kai Grossjohann
2004-11-24 14:03 ` Stefan Monnier
2004-11-25  9:54   ` Kai Grossjohann

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.