diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2010-11-15 19:10:38 +0000 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2010-11-15 19:10:38 +0000 |
commit | 3ce35a3d18441031614f78b8333d84e05d8d477c (patch) | |
tree | 1d53a8ae661808ec11e5196b7e668794f15e8724 /lib/proof-compat.el | |
parent | 04195f8f15c22cd8be7a471b9a7724deee687098 (diff) |
Summary: New indentation code using SMIE
* coq/coq.el (coq-build-prog-args): Avoid meaningless \- escape sequence.
(coq-use-smie): New custom var.
(coq-smie-grammar): New var.
(coq-smie-rules): New function.
(coq-guess-or-ask-for-string): Use use-region-p.
(coq-mode-config): Use smie-setup if available.
* lib/proof-compat.el (use-region-p): Provide fallback definition.
Diffstat (limited to 'lib/proof-compat.el')
-rw-r--r-- | lib/proof-compat.el | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/lib/proof-compat.el b/lib/proof-compat.el index a9fae654..3918b7ce 100644 --- a/lib/proof-compat.el +++ b/lib/proof-compat.el @@ -119,12 +119,12 @@ The value returned is the value of the last form in BODY." ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -;;; -;;; A naughty hack to completion.el -;;; -;;; At the moment IMO completion too eagerly adds stuff to -;;; its database: the completion-before-command function -;;; makes every suffix be added as a completion! +;; +;; A naughty hack to completion.el +;; +;; At the moment IMO completion too eagerly adds stuff to +;; its database: the completion-before-command function +;; makes every suffix be added as a completion! (eval-after-load "completion" '(defun completion-before-command () @@ -137,6 +137,10 @@ The value returned is the value of the last form in BODY." ;;; Backward compatibility for Emacs 22 ;;; +(or (fboundp 'use-region-p) + (defun use-region-p () + (and transient-mark-mode mark-active))) + (or (fboundp 'characterp) (defun characterp (obj) (with-no-warnings (char-valid-p obj)))) |