unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* `comment-start' is nil
@ 2014-03-12 21:37 lee
  2014-03-12 21:56 ` Juanma Barranquero
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: lee @ 2014-03-12 21:37 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

I´m using desktop-mode to restore the previous session when starting
emacs.  For some buffers that are restored this way, I´m using a mode
I´m working on.  This mode employs a function to search for a regex in
particular buffers.  The regex involves `comment-start'.

Unfortunately, at the time the function is running during start-up, the
value of `comment-start' is nil.


    (let ((end-marker (concat "^" comment-start lsl-hi-lock-patterns-end-marker)))
        (message "comment-start with %s is %s"
	   (buffer-name)
	   comment-start) ...)


gives me messages like "comment-start with test-plane.fontify is nil".
Calling the same function later works fine because `comment-start' isn´t
nil anymore.

Is it supposed to be like this, or is it a bug that `comment-start' is
nil?


I could work around it by setting `comment-start' to "# ", or by
omitting it, when it´s nil, but if it´s a bug, it should rather be
fixed ...


-- 
Knowledge is volatile and fluid.  Software is power.



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

end of thread, other threads:[~2014-03-16 17:18 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-12 21:37 `comment-start' is nil lee
2014-03-12 21:56 ` Juanma Barranquero
2014-03-15 20:50   ` lee
2014-03-12 22:26 ` Thorsten Jolitz
2014-03-13  6:36 ` Michael Heerdegen
2014-03-15 21:01   ` lee
2014-03-16 17:18     ` Stefan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).