From: Lars Ingebrigtsen Date: Mon, 17 Jun 2019 10:22:15 +0000 (+0200) Subject: Suppress compilation warning in srt-mode X-Git-Tag: emacs-27.0.90~2447 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=c90fc19c6ca27c2e280c5f0cdc0e2299c033f355;p=emacs.git Suppress compilation warning in srt-mode * lisp/cedet/srecode/srt-mode.el (srecode-parse-this-macro): Check for the existence of `key' in the macro before using it, and suppress the warning. --- diff --git a/lisp/cedet/srecode/srt-mode.el b/lisp/cedet/srecode/srt-mode.el index 660225925e0..0179929e7a9 100644 --- a/lisp/cedet/srecode/srt-mode.el +++ b/lisp/cedet/srecode/srt-mode.el @@ -511,7 +511,10 @@ section or ? for an ask variable." (split-string (oref inserter secondname) ":") nil))) - (key (oref inserter key))) + (key (when (slot-exists-p inserter 'key) + ;; This avoids a compilation warning, but we + ;; know that 'key exists here. + (slot-value inserter (intern "key" obarray))))) (cond ((null key) ;; A plain variable (cons nil base))