-;;; For emacs < 24.3.
-(require 'newcomment)
-(eval-and-compile
- (unless (fboundp 'user-error)
- (defalias 'user-error 'error))
- (unless (fboundp 'delete-consecutive-dups)
- (defalias 'delete-consecutive-dups 'delete-dups))
- (unless (fboundp 'completion-table-with-cache)
- (defun completion-table-with-cache (fun &optional ignore-case)
- ;; See eg bug#11906.
- (let* (last-arg last-result
- (new-fun
- (lambda (arg)
- (if (and last-arg (string-prefix-p last-arg arg ignore-case))
- last-result
- (prog1
- (setq last-result (funcall fun arg))
- (setq last-arg arg))))))
- (completion-table-dynamic new-fun)))))
-(eval-when-compile
- (unless (fboundp 'setq-local)
- (defmacro setq-local (var val)
- "Set variable VAR to value VAL in current buffer."
- (list 'set (list 'make-local-variable (list 'quote var)) val))))
-