From: Alex Branham <alex.branham@gmail.com>
To: 34290@debbugs.gnu.org
Subject: bug#34290: [PATCH] checkdoc byte compile warnings
Date: Sat, 02 Feb 2019 09:47:45 -0600 [thread overview]
Message-ID: <87zhre9opq.fsf@gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 210 bytes --]
Hi all -
The attached patch fixes the byte compiler warnings that checkdoc issues
currently by declaring the functions for the byte compiler. It also
removes some old XEmacs compatibility code.
Thanks,
Alex
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Fix-byte-compile-warnings-in-checkdoc.el.patch --]
[-- Type: text/x-patch, Size: 2244 bytes --]
From 78ec520b6214d768d340d0ab07159605e1f1b3e1 Mon Sep 17 00:00:00 2001
From: Alex Branham <alex.branham@gmail.com>
Date: Sat, 2 Feb 2019 09:45:11 -0600
Subject: [PATCH] Fix byte compile warnings in checkdoc.el
* lisp/emacs-lisp/checkdoc.el (checkdoc-file-comments-engine): Fix
byte compile warnings by declaring functions, remove XEmacs
compatibility code.
---
lisp/emacs-lisp/checkdoc.el | 18 +++++++-----------
1 file changed, 7 insertions(+), 11 deletions(-)
diff --git a/lisp/emacs-lisp/checkdoc.el b/lisp/emacs-lisp/checkdoc.el
index c0da61a589..1289e1cbc9 100644
--- a/lisp/emacs-lisp/checkdoc.el
+++ b/lisp/emacs-lisp/checkdoc.el
@@ -2205,21 +2205,17 @@ News agents may remove it"
;;
(defvar generate-autoload-cookie)
-(eval-when-compile (require 'lisp-mnt)) ; expand silly defsubsts
-(declare-function lm-summary "lisp-mnt" (&optional file))
-(declare-function lm-section-start "lisp-mnt" (header &optional after))
-(declare-function lm-section-end "lisp-mnt" (header))
+(declare-function lm-summary "lisp-mnt" (&optional file))
+(declare-function lm-commentary-mark "lisp-mnt")
+(declare-function lm-history-mark "lisp-mnt")
+(declare-function lm-code-mark "lisp-mnt")
+(declare-function lm-commentary-end "lisp-mnt")
(defun checkdoc-file-comments-engine ()
"Return a message list if this file does not match the Emacs standard.
This checks for style only, such as the first line, Commentary:,
Code:, and others referenced in the style guide."
- (if (featurep 'lisp-mnt)
- nil
- (require 'lisp-mnt)
- ;; Old XEmacs don't have `lm-commentary-mark'
- (if (and (not (fboundp 'lm-commentary-mark)) (fboundp 'lm-commentary))
- (defalias 'lm-commentary-mark #'lm-commentary)))
+ (require 'lisp-mnt)
(save-excursion
(let* ((f1 (file-name-nondirectory (buffer-file-name)))
(fn (file-name-sans-extension f1))
@@ -2280,7 +2276,7 @@ Code:, and others referenced in the style guide."
(if (or (not checkdoc-force-history-flag)
(file-exists-p "ChangeLog")
(file-exists-p "../ChangeLog")
- (and (fboundp 'lm-history-mark) (funcall #'lm-history-mark)))
+ (lm-history-mark))
nil
(progn
(goto-char (or (lm-commentary-mark) (point-min)))
--
2.19.2
next reply other threads:[~2019-02-02 15:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-02 15:47 Alex Branham [this message]
2019-02-02 16:06 ` bug#34290: [PATCH] checkdoc byte compile warnings Eli Zaretskii
2019-02-02 16:28 ` Alex Branham
2019-02-02 16:35 ` Eli Zaretskii
2019-02-08 22:27 ` Alex Branham
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87zhre9opq.fsf@gmail.com \
--to=alex.branham@gmail.com \
--cc=34290@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).