sjg@zen.oz.au (Simon J. Gerraty) (02/06/90)
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 <sjg@zen.oz> + ;; 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)))