unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined"
@ 2020-03-18  2:35 Daniel Kahn Gillmor
  2020-03-18  9:49 ` Örjan Ekeberg
  2020-03-18 17:11 ` [PATCH] emacs: avoid warning about notmuch-show-get-message-id Daniel Kahn Gillmor
  0 siblings, 2 replies; 5+ messages in thread
From: Daniel Kahn Gillmor @ 2020-03-18  2:35 UTC (permalink / raw)
  To: Notmuch Mail

[-- Attachment #1: Type: text/plain, Size: 618 bytes --]

When building the current version of notmuch on debian testing/unstable,
i see the following warning:

```
EMACS emacs/notmuch-crypto.elc

In end of data:
emacs/notmuch-crypto.el:266:1:Warning: the function
    ‘notmuch-show-get-message-id’ is not known to be defined.
```

No part of the test suite fails so i assume it's not a problem, but
having spurious warnings makes it harder to notice real warnings in the
future.

I don't know what the warning means exactly, but maybe someone who is
better with elisp than i am could take a look at it and try to resolve
it?

thanks,

        --dkg

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined"
  2020-03-18  2:35 notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined" Daniel Kahn Gillmor
@ 2020-03-18  9:49 ` Örjan Ekeberg
  2020-03-18 10:48   ` David Edmondson
  2020-03-18 17:11 ` [PATCH] emacs: avoid warning about notmuch-show-get-message-id Daniel Kahn Gillmor
  1 sibling, 1 reply; 5+ messages in thread
From: Örjan Ekeberg @ 2020-03-18  9:49 UTC (permalink / raw)
  To: Daniel Kahn Gillmor, Notmuch Mail

Daniel Kahn Gillmor <dkg@fifthhorseman.net> writes:

> When building the current version of notmuch on debian testing/unstable,
> i see the following warning:
>
> ```
> EMACS emacs/notmuch-crypto.elc
>
> In end of data:
> emacs/notmuch-crypto.el:266:1:Warning: the function
>     ‘notmuch-show-get-message-id’ is not known to be defined.
> ```
>
> No part of the test suite fails so i assume it's not a problem, but
> having spurious warnings makes it harder to notice real warnings in the
> future.
>
> I don't know what the warning means exactly, but maybe someone who is
> better with elisp than i am could take a look at it and try to resolve
> it?

Adding this line in notmuch-crypto.el solves this:

(declare-function notmuch-show-get-message-id "notmuch-show" (&optional bare))

As a matter of style, I am not sure where to put it.  Normally, these
declarations are put in the beginning of the file; right after the
require-statements.  In notmuch-crypto.el, however, the only other
declaration is put just in front of where the function is called.

/Örjan

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined"
  2020-03-18  9:49 ` Örjan Ekeberg
@ 2020-03-18 10:48   ` David Edmondson
  0 siblings, 0 replies; 5+ messages in thread
From: David Edmondson @ 2020-03-18 10:48 UTC (permalink / raw)
  To: Örjan Ekeberg, Daniel Kahn Gillmor, Notmuch Mail

On Wednesday, 2020-03-18 at 10:49:14 +01, Örjan Ekeberg wrote:

> Daniel Kahn Gillmor <dkg@fifthhorseman.net> writes:
>
>> When building the current version of notmuch on debian testing/unstable,
>> i see the following warning:
>>
>> ```
>> EMACS emacs/notmuch-crypto.elc
>>
>> In end of data:
>> emacs/notmuch-crypto.el:266:1:Warning: the function
>>     ‘notmuch-show-get-message-id’ is not known to be defined.
>> ```
>>
>> No part of the test suite fails so i assume it's not a problem, but
>> having spurious warnings makes it harder to notice real warnings in the
>> future.
>>
>> I don't know what the warning means exactly, but maybe someone who is
>> better with elisp than i am could take a look at it and try to resolve
>> it?
>
> Adding this line in notmuch-crypto.el solves this:
>
> (declare-function notmuch-show-get-message-id "notmuch-show" (&optional bare))
>
> As a matter of style, I am not sure where to put it.  Normally, these
> declarations are put in the beginning of the file; right after the
> require-statements.  In notmuch-crypto.el, however, the only other
> declaration is put just in front of where the function is called.

As you say, we normally gather them near to the top of the file.

dme.
-- 
My girl Friday, she no square.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH] emacs: avoid warning about notmuch-show-get-message-id
  2020-03-18  2:35 notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined" Daniel Kahn Gillmor
  2020-03-18  9:49 ` Örjan Ekeberg
@ 2020-03-18 17:11 ` Daniel Kahn Gillmor
  2020-03-23  1:39   ` David Bremner
  1 sibling, 1 reply; 5+ messages in thread
From: Daniel Kahn Gillmor @ 2020-03-18 17:11 UTC (permalink / raw)
  To: Notmuch Mail

Without this change, we see the following warning when compiling the
elisp:

```
EMACS emacs/notmuch-crypto.elc

In end of data:
emacs/notmuch-crypto.el:266:1:Warning: the function
    ‘notmuch-show-get-message-id’ is not known to be defined.
```

Thanks to Örjan Ekeberg and David Edmondson for their followup about
this.

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
---
 emacs/notmuch-crypto.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/emacs/notmuch-crypto.el b/emacs/notmuch-crypto.el
index 4035ee37..928de0bb 100644
--- a/emacs/notmuch-crypto.el
+++ b/emacs/notmuch-crypto.el
@@ -163,6 +163,7 @@ by user FROM."
       (recenter -1))))
 
 (declare-function notmuch-show-refresh-view "notmuch-show" (&optional reset-state))
+(declare-function notmuch-show-get-message-id "notmuch-show" (&optional bare))
 
 (defun notmuch-crypto--async-key-sentinel (process event)
   "When the user asks for a GPG key to be retrieved
-- 
2.25.1

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] emacs: avoid warning about notmuch-show-get-message-id
  2020-03-18 17:11 ` [PATCH] emacs: avoid warning about notmuch-show-get-message-id Daniel Kahn Gillmor
@ 2020-03-23  1:39   ` David Bremner
  0 siblings, 0 replies; 5+ messages in thread
From: David Bremner @ 2020-03-23  1:39 UTC (permalink / raw)
  To: Daniel Kahn Gillmor, Notmuch Mail

Daniel Kahn Gillmor <dkg@fifthhorseman.net> writes:

> Without this change, we see the following warning when compiling the
> elisp:
>

pushed

d

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-03-23  1:39 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-18  2:35 notmuch-crypto.el: "‘notmuch-show-get-message-id’ is not known to be defined" Daniel Kahn Gillmor
2020-03-18  9:49 ` Örjan Ekeberg
2020-03-18 10:48   ` David Edmondson
2020-03-18 17:11 ` [PATCH] emacs: avoid warning about notmuch-show-get-message-id Daniel Kahn Gillmor
2020-03-23  1:39   ` David Bremner

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.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).