diff options
| author | Glenn Morris | 2007-12-01 03:40:41 +0000 |
|---|---|---|
| committer | Glenn Morris | 2007-12-01 03:40:41 +0000 |
| commit | 5ba3c59a5b388f7a51b3e90a27882f45cb89dbbd (patch) | |
| tree | 9171311b20533d5a8747609b9929bf6f623ca0ee | |
| parent | afa803d576eb966d7180190312c33a949459ae72 (diff) | |
| download | emacs-5ba3c59a5b388f7a51b3e90a27882f45cb89dbbd.tar.gz emacs-5ba3c59a5b388f7a51b3e90a27882f45cb89dbbd.zip | |
(iswitchb-temp-buflist, iswitchb-read-buffer): Declare for compiler.
(erc-iswitchb): Don't require iswitchb when compiling. Test
iswitchb-mode is bound.
| -rw-r--r-- | lisp/erc/erc.el | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index c6e5ea99c83..f078ee32a79 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el | |||
| @@ -1693,6 +1693,11 @@ nil." | |||
| 1693 | (put 'erc-with-all-buffers-of-server 'lisp-indent-function 1) | 1693 | (put 'erc-with-all-buffers-of-server 'lisp-indent-function 1) |
| 1694 | (put 'erc-with-all-buffers-of-server 'edebug-form-spec '(form form body)) | 1694 | (put 'erc-with-all-buffers-of-server 'edebug-form-spec '(form form body)) |
| 1695 | 1695 | ||
| 1696 | ;; (iswitch-mode) will autoload iswitchb.el | ||
| 1697 | (defvar iswitchb-temp-buflist) | ||
| 1698 | (declare-function iswitchb-read-buffer "iswitchb" | ||
| 1699 | (prompt &optional default require-match start matches-set)) | ||
| 1700 | |||
| 1696 | (defun erc-iswitchb (&optional arg) | 1701 | (defun erc-iswitchb (&optional arg) |
| 1697 | "Use `iswitchb-read-buffer' to prompt for a ERC buffer to switch to. | 1702 | "Use `iswitchb-read-buffer' to prompt for a ERC buffer to switch to. |
| 1698 | When invoked with prefix argument, use all erc buffers. Without prefix | 1703 | When invoked with prefix argument, use all erc buffers. Without prefix |
| @@ -1703,9 +1708,7 @@ If `erc-track-mode' is in enabled, put the last element of | |||
| 1703 | Due to some yet unresolved reason, global function `iswitchb-mode' | 1708 | Due to some yet unresolved reason, global function `iswitchb-mode' |
| 1704 | needs to be active for this function to work." | 1709 | needs to be active for this function to work." |
| 1705 | (interactive "P") | 1710 | (interactive "P") |
| 1706 | (eval-when-compile | 1711 | (let ((enabled (bound-and-true-p iswitchb-mode))) |
| 1707 | (require 'iswitchb)) | ||
| 1708 | (let ((enabled iswitchb-mode)) | ||
| 1709 | (or enabled (iswitchb-mode 1)) | 1712 | (or enabled (iswitchb-mode 1)) |
| 1710 | (unwind-protect | 1713 | (unwind-protect |
| 1711 | (let ((iswitchb-make-buflist-hook | 1714 | (let ((iswitchb-make-buflist-hook |