aboutsummaryrefslogtreecommitdiffhomepage
path: root/coq/coq.el
diff options
context:
space:
mode:
authorGravatar Pierre Courtieu <Pierre.Courtieu@cnam.fr>2016-03-09 18:40:34 +0100
committerGravatar Pierre Courtieu <Pierre.Courtieu@cnam.fr>2016-03-09 18:40:34 +0100
commite2c5da005b1b29e1da3c1b2bf1c6de45d3d78b1a (patch)
tree559b25768af1d621383f6dc51e1a86b03803c862 /coq/coq.el
parentbfedfed9d1f5d245a0fc4b40a5029cfd4c666c27 (diff)
Fix #64. Use syntax-ppss in fill-nobreak-predicate.
More robust to font-lock tweaks that change font inside comments (whitespace mode etc).
Diffstat (limited to 'coq/coq.el')
-rw-r--r--coq/coq.el3
1 files changed, 1 insertions, 2 deletions
diff --git a/coq/coq.el b/coq/coq.el
index bde53667..656d2b54 100644
--- a/coq/coq.el
+++ b/coq/coq.el
@@ -1480,8 +1480,7 @@ Near here means PT is either inside or just aside of a comment."
(set (make-local-variable 'open-paren-in-column-0-is-defun-start) nil)
;; do not break lines in code when filling
(set (make-local-variable 'fill-nobreak-predicate)
- (lambda ()
- (not (eq (get-text-property (point) 'face) 'font-lock-comment-face))))
+ (lambda () (not (syntax-ppss))))
;; coq mode specific indentation function
(set (make-local-variable 'fill-paragraph-function) 'coq-fill-paragraph-function)