aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorGravatar David Aspinall <da@inf.ed.ac.uk>2010-08-25 08:42:44 +0000
committerGravatar David Aspinall <da@inf.ed.ac.uk>2010-08-25 08:42:44 +0000
commit9a771e0f787216593070c66dfaed3b9ea2007e81 (patch)
tree405875480d1aabdae5f67074fc91a2bb4af2c98e /lib
parent44ff04eef9a3c1c9e499eb9f1c98db0765cdabb4 (diff)
Bring syntactic context functions together
Diffstat (limited to 'lib')
-rw-r--r--lib/proof-compat.el34
1 files changed, 1 insertions, 33 deletions
diff --git a/lib/proof-compat.el b/lib/proof-compat.el
index 4c77c34a..a9fae654 100644
--- a/lib/proof-compat.el
+++ b/lib/proof-compat.el
@@ -1,6 +1,6 @@
;; proof-compat.el Operating system and Emacs version compatibility
;;
-;; Copyright (C) 2000-2009 LFCS Edinburgh.
+;; Copyright (C) 2000-2010 LFCS Edinburgh.
;; Author: David Aspinall <David.Aspinall@ed.ac.uk> and others
;; License: GPL (GNU GENERAL PUBLIC LICENSE)
;;
@@ -91,30 +91,6 @@ The value returned is the value of the last form in BODY."
(progn ,@body)
(select-frame ,old-frame))))))
-;; An implemenation of buffer-syntactic-context for GNU Emacs
-(defun proof-buffer-syntactic-context-emulate (&optional buffer)
- "Return the syntactic context of BUFFER at point.
-If BUFFER is nil or omitted, the current buffer is assumed.
-The returned value is one of the following symbols:
-
- nil ; meaning no special interpretation
- string ; meaning point is within a string
- comment ; meaning point is within a line comment"
- (save-excursion
- (if buffer (set-buffer buffer))
- (let ((pp (syntax-ppss)))
- ;;(parse-partial-sexp (point-min) (point))))
- (cond
- ((nth 3 pp) 'string)
- ;; ((nth 7 pp) 'block-comment)
- ;; "Stefan Monnier" <monnier+misc/news@rum.cs.yale.edu> suggests
- ;; distinguishing between block comments and ordinary comments
- ;; is problematic: not what XEmacs claims and different to what
- ;; (nth 7 pp) tells us in GNU Emacs.
- ((nth 4 pp) 'comment)))))
-
-
-
;; These functions are used in the intricate logic around
;; shrink-to-fit.
@@ -158,14 +134,6 @@ The returned value is one of the following symbols:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
-;;; General Emacs version compatibility
-;;;
-
-(defalias 'proof-buffer-syntactic-context
- 'proof-buffer-syntactic-context-emulate)
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-;;;
;;; Backward compatibility for Emacs 22
;;;