From 153ef845b8355e243c2adcf1ea52fb55636683d8 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Tue, 20 Nov 2007 00:57:10 +0000 Subject: [PATCH] * progmodes/idlw-help.el: Require browse-url unconditionally, it is available by default. (idlwave-help-browse-url-available): Change default to t. * emulation/edt.el (defgroup, defcustom): Remove definition. (eval-when-compile): Remove. (c-mark-function): * textmodes/reftex-dcr.el (bibtex-beginning-of-entry): * textmodes/fill.el (comment-search-forward) (comment-string-strip): * progmodes/prolog.el (comint-mode, comint-send-string) (comint-send-region, comint-send-eof): * progmodes/dcl-mode.el (imenu-default-create-index-function): * emulation/viper-util.el (viper-forward-Word): * emulation/vi.el (c-mark-function): * emulation/edt-vt100.el (vt100-wide-mode): * emacs-lisp/timer.el (diary-entry-time): Declare as functions. * url-mailto.el (mail-send-and-exit): * url-http.el (url-dav-file-attributes): * url-file.el (ange-ftp-set-passwd, ange-ftp-copy-file-internal): Declare as functions. * url-privacy.el (url-device-type): Define unconditionally. --- lisp/ChangeLog | 20 ++++++++++++++++++++ lisp/emacs-lisp/timer.el | 3 +++ lisp/emulation/edt-vt100.el | 2 ++ lisp/emulation/edt.el | 34 +++++++++++++--------------------- lisp/emulation/vi.el | 2 ++ lisp/emulation/viper-util.el | 2 ++ lisp/progmodes/dcl-mode.el | 1 + lisp/progmodes/idlw-help.el | 7 ++----- lisp/progmodes/prolog.el | 5 +++++ lisp/textmodes/fill.el | 4 ++++ lisp/textmodes/reftex-dcr.el | 2 ++ lisp/url/ChangeLog | 9 +++++++++ lisp/url/url-file.el | 5 +++++ lisp/url/url-http.el | 2 ++ lisp/url/url-mailto.el | 2 ++ lisp/url/url-privacy.el | 7 ++++--- 16 files changed, 78 insertions(+), 29 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2aa2ba6575d..784c2d09da8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,23 @@ +2007-11-20 Dan Nicolaescu + + * progmodes/idlw-help.el: Require browse-url unconditionally, it + is available by default. + (idlwave-help-browse-url-available): Change default to t. + + * emulation/edt.el (defgroup, defcustom): Remove definition. + (eval-when-compile): Remove. + (c-mark-function): + * textmodes/reftex-dcr.el (bibtex-beginning-of-entry): + * textmodes/fill.el (comment-search-forward) + (comment-string-strip): + * progmodes/prolog.el (comint-mode, comint-send-string) + (comint-send-region, comint-send-eof): + * progmodes/dcl-mode.el (imenu-default-create-index-function): + * emulation/viper-util.el (viper-forward-Word): + * emulation/vi.el (c-mark-function): + * emulation/edt-vt100.el (vt100-wide-mode): + * emacs-lisp/timer.el (diary-entry-time): Declare as functions. + 2007-11-19 Michael Albinus * net/tramp.el (tramp-open-connection-setup-interactive-shell): diff --git a/lisp/emacs-lisp/timer.el b/lisp/emacs-lisp/timer.el index 0fed5962fcb..023a4a3e4b7 100644 --- a/lisp/emacs-lisp/timer.el +++ b/lisp/emacs-lisp/timer.el @@ -356,6 +356,9 @@ This function is called, by name, directly by the C code." "Non-nil if EVENT is a timeout event." (and (listp event) (eq (car event) 'timer-event))) + +(declare-function diary-entry-time "../calendar/diary-lib" (s)) + ;;;###autoload (defun run-at-time (time repeat function &rest args) "Perform an action at time TIME. diff --git a/lisp/emulation/edt-vt100.el b/lisp/emulation/edt-vt100.el index 4e094a5f703..fbe56c2c341 100644 --- a/lisp/emulation/edt-vt100.el +++ b/lisp/emulation/edt-vt100.el @@ -39,6 +39,8 @@ ;; The following functions are called by the EDT screen width commands defined ;; in edt.el. +(declare-function vt100-wide-mode "../term/vt100" (&optional arg)) + (defun edt-set-term-width-80 () "Set terminal width to 80 columns." (vt100-wide-mode -1)) diff --git a/lisp/emulation/edt.el b/lisp/emulation/edt.el index 4a68e258cb1..d61ef9725f3 100644 --- a/lisp/emulation/edt.el +++ b/lisp/emulation/edt.el @@ -166,28 +166,23 @@ ;;;; VARIABLES and CONSTANTS ;;;; -;; For backward compatibility to Emacs 19. -(or (fboundp 'defgroup) - (defmacro defgroup (&rest rest))) - (defgroup edt nil "Emacs emulating EDT." :prefix "edt-" :group 'emulations) ;; To silence the byte-compiler -(eval-when-compile - (defvar *EDT-keys*) - (defvar edt-default-global-map) - (defvar edt-last-copied-word) - (defvar edt-learn-macro-count) - (defvar edt-orig-page-delimiter) - (defvar edt-orig-transient-mark-mode) - (defvar edt-rect-start-point) - (defvar edt-user-global-map) - (defvar rect-start-point) - (defvar time-string) - (defvar zmacs-region-stays)) +(defvar *EDT-keys*) +(defvar edt-default-global-map) +(defvar edt-last-copied-word) +(defvar edt-learn-macro-count) +(defvar edt-orig-page-delimiter) +(defvar edt-orig-transient-mark-mode) +(defvar edt-rect-start-point) +(defvar edt-user-global-map) +(defvar rect-start-point) +(defvar time-string) +(defvar zmacs-region-stays) ;;; ;;; Version Information @@ -198,11 +193,6 @@ ;;; User Configurable Variables ;;; -;; For backward compatibility to Emacs 19. -(or (fboundp 'defcustom) - (defmacro defcustom (var value doc &rest ignore) - `(defvar ,var ,value ,doc))) - (defcustom edt-keep-current-page-delimiter nil "*Emacs MUST be restarted for a change in value to take effect! Non-nil leaves Emacs value of `page-delimiter' unchanged within EDT @@ -1628,6 +1618,8 @@ Argument NUM is the percentage into the buffer to move." (indent-region (point) (mark) nil) (fill-region (point) (mark)))) + +(declare-function c-mark-function "../progmodes/cc-cmds" ()) ;;; ;;; MARK SECTION WISELY ;;; diff --git a/lisp/emulation/vi.el b/lisp/emulation/vi.el index 81ad04b60d9..889f81e75c7 100644 --- a/lisp/emulation/vi.el +++ b/lisp/emulation/vi.el @@ -1375,6 +1375,8 @@ The following CHAR will be the name for the command or macro." (setq char (read-char)) (vi-ask-for-info char)))) +(declare-function c-mark-function "../progmodes/cc-cmds" ()) + (defun vi-mark-region (arg region) "Mark region appropriately. The next char REGION is d(efun),s(-exp),b(uffer), p(aragraph), P(age), f(unction in C/Pascal etc.), w(ord), e(nd of sentence), diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index c757eb63aef..6a21fa17e31 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el @@ -380,6 +380,8 @@ +(declare-function viper-forward-Word "viper-cmd" (arg)) + ;;; Support for :e, :r, :w file globbing ;; Glob the file spec. diff --git a/lisp/progmodes/dcl-mode.el b/lisp/progmodes/dcl-mode.el index 6a3e9e82d6e..5df2c72b7e0 100644 --- a/lisp/progmodes/dcl-mode.el +++ b/lisp/progmodes/dcl-mode.el @@ -2201,6 +2201,7 @@ otherwise return nil." () (equal start (match-end 0)))))) +(declare-function imenu-default-create-index-function "../imenu" ()) ;;;------------------------------------------------------------------------- (defun dcl-imenu-create-index-function () diff --git a/lisp/progmodes/idlw-help.el b/lisp/progmodes/idlw-help.el index 2269e179357..b599baa2893 100644 --- a/lisp/progmodes/idlw-help.el +++ b/lisp/progmodes/idlw-help.el @@ -42,13 +42,10 @@ ;;; Code: -(defvar idlwave-help-browse-url-available nil +(defvar idlwave-help-browse-url-available t "Whether browse-url is available") -(setq idlwave-help-browse-url-available - (condition-case nil - (require 'browse-url) - (error nil))) +(require 'browse-url) (defgroup idlwave-online-help nil "Online Help options for IDLWAVE mode." diff --git a/lisp/progmodes/prolog.el b/lisp/progmodes/prolog.el index 3583f546754..190442bf26e 100644 --- a/lisp/progmodes/prolog.el +++ b/lisp/progmodes/prolog.el @@ -240,6 +240,11 @@ rigidly along with this one (not yet)." (defvar inferior-prolog-mode-syntax-table prolog-mode-syntax-table) (defvar inferior-prolog-mode-abbrev-table prolog-mode-abbrev-table) +(declare-function comint-mode "../comint") +(declare-function comint-send-string "../comint" (process string)) +(declare-function comint-send-region "../comint" (process start end)) +(declare-function comint-send-eof "../comint" ()) + (define-derived-mode inferior-prolog-mode comint-mode "Inferior Prolog" "Major mode for interacting with an inferior Prolog process. diff --git a/lisp/textmodes/fill.el b/lisp/textmodes/fill.el index 6a0eb7a42cc..cd60cf3bf34 100644 --- a/lisp/textmodes/fill.el +++ b/lisp/textmodes/fill.el @@ -831,6 +831,10 @@ in the active region." (fill-region-as-paragraph beg end justify)))))) fill-pfx))) +(declare-function comment-search-forward "../newcomment" (limit &optional noerror)) +(declare-function comment-string-strip "../newcomment" (str beforep afterp)) + + (defun fill-comment-paragraph (&optional justify) "Fill current comment. If we're not in a comment, just return nil so that the caller diff --git a/lisp/textmodes/reftex-dcr.el b/lisp/textmodes/reftex-dcr.el index e1ecc885f69..86ad54a73fa 100644 --- a/lisp/textmodes/reftex-dcr.el +++ b/lisp/textmodes/reftex-dcr.el @@ -359,6 +359,8 @@ will display info in the echo area." 'reftex-view-crossref-when-idle reftex-idle-time nil t)))) +(declare-function bibtex-beginning-of-entry "bibtex" ()) + (defun reftex-view-crossref-from-bibtex (&optional arg) "View location in a LaTeX document which cites the BibTeX entry at point. Since BibTeX files can be used by many LaTeX documents, this function diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog index 93552c15ea9..56df401cb53 100644 --- a/lisp/url/ChangeLog +++ b/lisp/url/ChangeLog @@ -1,3 +1,12 @@ +2007-11-20 Dan Nicolaescu + + * url-mailto.el (mail-send-and-exit): + * url-http.el (url-dav-file-attributes): + * url-file.el (ange-ftp-set-passwd, ange-ftp-copy-file-internal): + Declare as functions. + + * url-privacy.el (url-device-type): Define unconditionally. + 2007-10-31 Juanma Barranquero * url-vars.el (url-vars-unload-hook): Remove function and variable. diff --git a/lisp/url/url-file.el b/lisp/url/url-file.el index c361016856b..9faee051f46 100644 --- a/lisp/url/url-file.el +++ b/lisp/url/url-file.el @@ -86,6 +86,11 @@ to them." (error nil))) (apply func args)))) +(declare-function ange-ftp-set-passwd "../net/ange-ftp" (host user passwd)) +(declare-function ange-ftp-copy-file-internal "../net/ange-ftp" + (filename newname ok-if-already-exists + keep-date &optional msg cont nowait)) + (defun url-file-build-filename (url) (if (not (vectorp url)) (setq url (url-generic-parse-url url))) diff --git a/lisp/url/url-http.el b/lisp/url/url-http.el index c5931c7d877..c8447dab859 100644 --- a/lisp/url/url-http.el +++ b/lisp/url/url-http.el @@ -1269,6 +1269,8 @@ CBARGS as the arguments." nil nil nil) ;whether gid would change ; inode ; device. (kill-buffer buffer))))) +(declare-function url-dav-file-attributes (url &optional id-format)) + ;;;###autoload (defun url-http-file-attributes (url &optional id-format) (if (url-dav-supported-p url) diff --git a/lisp/url/url-mailto.el b/lisp/url/url-mailto.el index 4b15d07245b..5004c62415c 100644 --- a/lisp/url/url-mailto.el +++ b/lisp/url/url-mailto.el @@ -60,6 +60,8 @@ (save-excursion (insert "\n")))))) +(declare-function mail-send-and-exit "../mail/sendmail") + ;;;###autoload (defun url-mailto (url) "Handle the mailto: URL syntax." diff --git a/lisp/url/url-privacy.el b/lisp/url/url-privacy.el index 6c29474752b..886e545ae7d 100644 --- a/lisp/url/url-privacy.el +++ b/lisp/url/url-privacy.el @@ -27,9 +27,10 @@ (eval-when-compile (require 'cl)) (require 'url-vars) -(if (fboundp 'device-type) - (defalias 'url-device-type 'device-type) - (defun url-device-type (&optional device) (or window-system 'tty))) +(defun url-device-type (&optional device) + (if (fboundp 'device-type) + (url-device-type device) + (or window-system 'tty))) ;;;###autoload (defun url-setup-privacy-info () -- 2.39.2