]> git.eshelyaron.com Git - emacs.git/commitdiff
CC Mode: Fix error in macro cache. This fixes bug #36802
authorAlan Mackenzie <acm@muc.de>
Fri, 2 Aug 2019 13:38:13 +0000 (13:38 +0000)
committerAlan Mackenzie <acm@muc.de>
Fri, 2 Aug 2019 13:39:57 +0000 (13:39 +0000)
* lisp/progmodes/cc-engine.el (c-invalidate-macro-cache): Add in a cond arm
to handle the change position being less than the recorded CPP contruct end.

lisp/progmodes/cc-engine.el

index 37d4591fc962204ff78397a017fbe9e459b7e59d..a095277989a8579acc808a40f044b93f01d639d4 100644 (file)
    ((and (cdr c-macro-cache)
         (< beg (cdr c-macro-cache)))
     (setcdr c-macro-cache nil)
+    (setq c-macro-cache-start-pos beg
+         c-macro-cache-syntactic nil
+         c-macro-cache-no-comment nil))
+   ((and c-macro-cache-start-pos
+        (< beg c-macro-cache-start-pos))
     (setq c-macro-cache-start-pos beg
          c-macro-cache-syntactic nil
          c-macro-cache-no-comment nil))))