Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!uwm.edu!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!tut.cis.ohio-state.edu!zen.oz.au!sjg From: sjg@zen.oz.au (Simon J. Gerraty) Newsgroups: gnu.emacs.bug Subject: c-mode bug? Message-ID: <9002051244.AA07090@zen> Date: 6 Feb 90 04:44:10 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 30 In c-mode; if point is below a line such as (at top level); char foo="()"; calculate-c-indent is fooled into thinking that it should apply c-argdecl-indent. This used to drive me nuts since all my .c files have; static char *sccs_id = "%Z%%M% ... (%Y%)"; The following patch "seems" to fix the problem: *** /usr/local/lib/emacs-18.53/lisp/c-mode.el Thu Feb 1 22:46:28 1990 --- c-mode.el Mon Feb 5 23:25:36 1990 *************** *** 386,391 **** --- 386,397 ---- (save-excursion (re-search-backward "^[^ \^L\t\n#]" nil 'move) (if (and (looking-at "\\sw\\|\\s_") + ;; 90-02-05 + ;; used to muck up if something like + ;; char foo="()"; + ;; was in the buffer, next line seems to + ;; fix it. + (not (looking-at ".*\"[^\"]*(")) (looking-at ".*(") (progn (goto-char (1- (match-end 0)))