comparison lisp/newcomment.el @ 54279:41d93a97701d

(comment-normalize-vars): Check the user-specified comment start marker.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Thu, 04 Mar 2004 20:02:52 +0000
parents 0c512d4c08e1
children 597fb06dcdda
comparison
equal deleted inserted replaced
54278:e83b2d0cd614 54279:41d93a97701d
249 Functions autoloaded from newcomment.el, being entry points, should call 249 Functions autoloaded from newcomment.el, being entry points, should call
250 this function before any other, so the rest of the code can assume that 250 this function before any other, so the rest of the code can assume that
251 the variables are properly set." 251 the variables are properly set."
252 (unless (and (not comment-start) noerror) 252 (unless (and (not comment-start) noerror)
253 (unless comment-start 253 (unless comment-start
254 (set (make-local-variable 'comment-start) 254 (let ((cs (read-string "No comment syntax is defined. Use: ")))
255 (read-string "No comment syntax is defined. Use: "))) 255 (if (zerop (length cs))
256 (error "No comment syntax defined")
257 (set (make-local-variable 'comment-start) cs))))
256 ;; comment-use-syntax 258 ;; comment-use-syntax
257 (when (eq comment-use-syntax 'undecided) 259 (when (eq comment-use-syntax 'undecided)
258 (set (make-local-variable 'comment-use-syntax) 260 (set (make-local-variable 'comment-use-syntax)
259 (let ((st (syntax-table)) 261 (let ((st (syntax-table))
260 (cs comment-start) 262 (cs comment-start)