emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/git-commit a0f3bb0 1/3: Make check-declare happy


From: ELPA Syncer
Subject: [nongnu] elpa/git-commit a0f3bb0 1/3: Make check-declare happy
Date: Tue, 7 Dec 2021 18:57:57 -0500 (EST)

branch: elpa/git-commit
commit a0f3bb0d9c16bdaef7df8348c5d0d4748fb27f27
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>

    Make check-declare happy
    
    This addresses approximately five real issues and five
    false-positives.
---
 lisp/magit-apply.el | 4 ++--
 lisp/magit-diff.el  | 9 +++++----
 lisp/magit-git.el   | 3 ++-
 lisp/magit-mode.el  | 2 +-
 lisp/magit-repos.el | 2 +-
 lisp/magit-utils.el | 7 ++-----
 6 files changed, 13 insertions(+), 14 deletions(-)

diff --git a/lisp/magit-apply.el b/lisp/magit-apply.el
index fbd7e70..a44b767 100644
--- a/lisp/magit-apply.el
+++ b/lisp/magit-apply.el
@@ -39,8 +39,8 @@
 (require 'transient) ; See #3732.
 
 ;; For `magit-apply'
-(declare-function magit-am "magit-sequence" ())
-(declare-function magit-patch-apply "magit-files" ())
+(declare-function magit-am "magit-sequence" () t)
+(declare-function magit-patch-apply "magit-patch" () t)
 ;; For `magit-discard-files'
 (declare-function magit-checkout-stage "magit-merge" (file arg))
 (declare-function magit-checkout-read-stage "magit-merge" (file))
diff --git a/lisp/magit-diff.el b/lisp/magit-diff.el
index f251bae..f1fccdb 100644
--- a/lisp/magit-diff.el
+++ b/lisp/magit-diff.el
@@ -41,15 +41,16 @@
 ;; For `magit-diff-popup'
 (declare-function magit-stash-show "magit-stash" (stash &optional args files))
 ;; For `magit-diff-visit-file'
-(declare-function dired-jump "dired-x" (&optional other-window file-name))
+(declare-function dired-jump "dired" ; dired-x before 27.1
+                  (&optional other-window file-name))
 (declare-function magit-find-file-noselect "magit-files" (rev file))
-(declare-function magit-status-setup-buffer "magit-status" (directory))
+(declare-function magit-status-setup-buffer "magit-status" (&optional 
directory))
 ;; For `magit-diff-while-committing'
 (declare-function magit-commit-message-buffer "magit-commit" ())
 ;; For `magit-insert-revision-gravatar'
 (defvar gravatar-size)
 ;; For `magit-show-commit' and `magit-diff-show-or-scroll'
-(declare-function magit-current-blame-chunk "magit-blame" ())
+(declare-function magit-current-blame-chunk "magit-blame" (&optional type 
noerror))
 (declare-function magit-blame-mode "magit-blame" (&optional arg))
 (defvar magit-blame-mode)
 ;; For `magit-diff-show-or-scroll'
@@ -62,7 +63,7 @@
                   (pullreq &optional endpoints))
 (declare-function forge--pullreq-ref "forge-pullreq" (pullreq))
 ;; For `magit-diff-wash-diff'
-(declare-function ansi-color-apply-on-region "ansi-color" (begin end))
+(declare-function ansi-color-apply-on-region "ansi-color")
 
 (eval-when-compile
   (cl-pushnew 'orig-rev eieio--known-slot-names)
diff --git a/lisp/magit-git.el b/lisp/magit-git.el
index 8fbeab9..d231580 100644
--- a/lisp/magit-git.el
+++ b/lisp/magit-git.el
@@ -53,7 +53,8 @@
 ;; From `magit-process'.
 (declare-function magit-call-git "magit-process" (&rest args))
 (declare-function magit-process-buffer "magit-process" (&optional nodisplay))
-(declare-function magit-process-file "magit-process" (&rest args))
+(declare-function magit-process-file "magit-process"
+                  (process &optional infile buffer display &rest args))
 (declare-function magit-process-git "magit-process" (destination &rest args))
 (declare-function magit-process-insert-section "magit-process"
                   (pwd program args &optional errcode errlog))
diff --git a/lisp/magit-mode.el b/lisp/magit-mode.el
index 59b8fd0..09fe82e 100644
--- a/lisp/magit-mode.el
+++ b/lisp/magit-mode.el
@@ -49,7 +49,7 @@
 ;; For `magit-refresh-buffer'
 (declare-function magit-process-unset-mode-line-error-status "magit-process" 
())
 ;; For `magit-refresh-get-relative-position'
-(declare-function magit-hunk-section-p "magit-diff" (obj))
+(declare-function magit-hunk-section-p "magit-diff" (section) t)
 ;; For `magit-mode-setup-internal'
 (declare-function magit-status-goto-initial-section "magit-status" ())
 ;; For `magit-mode' from `bookmark'
diff --git a/lisp/magit-repos.el b/lisp/magit-repos.el
index 0224708..64d2a97 100644
--- a/lisp/magit-repos.el
+++ b/lisp/magit-repos.el
@@ -33,7 +33,7 @@
 
 (require 'magit-core)
 
-(declare-function magit-status-setup-buffer "magit-status" (directory))
+(declare-function magit-status-setup-buffer "magit-status" (&optional 
directory))
 
 (defvar x-stretch-cursor)
 
diff --git a/lisp/magit-utils.el b/lisp/magit-utils.el
index bfd2827..ea3715e 100644
--- a/lisp/magit-utils.el
+++ b/lisp/magit-utils.el
@@ -49,10 +49,6 @@
 (require 'crm)
 
 (eval-when-compile (require 'ido))
-(declare-function ido-completing-read+ "ido-completing-read+"
-                  (prompt collection &optional predicate
-                          require-match initial-input
-                          hist def inherit-input-method))
 (declare-function Info-get-token "info" (pos start all &optional errorstring))
 
 (eval-when-compile (require 'vc-git))
@@ -663,7 +659,8 @@ Unfortunately `ido-completing-read' is not suitable as a
 drop-in replacement for `completing-read', instead we use
 `ido-completing-read+' from the third-party package by the
 same name."
-  (if (require 'ido-completing-read+ nil t)
+  (if (and (require 'ido-completing-read+ nil t)
+           (fboundp 'ido-completing-read+))
       (ido-completing-read+ prompt choices predicate require-match
                             initial-input hist
                             (or def (and require-match (car choices))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]