]> code.delx.au - gnu-emacs/commitdiff
(c-emacs-features): Do parse-partial-sexp at point, in case of narrowing.
authorRichard M. Stallman <rms@gnu.org>
Mon, 26 Dec 2005 04:51:46 +0000 (04:51 +0000)
committerRichard M. Stallman <rms@gnu.org>
Mon, 26 Dec 2005 04:51:46 +0000 (04:51 +0000)
lisp/progmodes/cc-defs.el

index 1bb76c170dc5aa0f1bf9980529378af266304c4d..b237dd9a5987ee4236f4eb3e7e9d84ad921dd412 100644 (file)
@@ -1464,7 +1464,8 @@ non-nil, a caret is prepended to invert the set."
       (kill-buffer buf))
 
     ;; See if `parse-partial-sexp' returns the eighth element.
-    (if (c-safe (>= (length (save-excursion (parse-partial-sexp 1 1))) 10))
+    (if (c-safe (>= (length (save-excursion (parse-partial-sexp (point) (point))))
+                   10))
        (setq list (cons 'pps-extended-state list))
       (error (concat
              "CC Mode is incompatible with this version of Emacs - "