Subject: bug#15987: 24.3; diary-add-to-list ignored by diary-mark-entries

From: "Roland Winkler" <[email-masked]>
Date: Thu, 28 Nov 2013 08:40:39 -0600

I am not an expert with diary and calendar, but it seems to me that
there is an unnecessary duplication of code in diary-list-entries
and diary-mark-entries making it rather difficult to feed entries
into diary-mark-entries if these entries do not come from a diary
file.

The context is the following:

BBDB 3 defines the function bbdb-anniv-diary-entries which adds
anniversaries from BBDB records to `diary-list-entries' by calling
diary-add-to-list.  This is a clean thing and works fine.

Now I've been asked on the BBDB mailing list how these anniversaries
from BBDB records can also be marked in the Emacs calendar, and it
seems to me that there is no easy way to achieve this.  The problem
seems to be that diary-add-to-list is used to set up the diary
buffer.  But diary-mark-entries (or more specifically
diary-mark-entries-1) parses the diary file(s) similarly to what
diary-list-entries is doing; but this is directly used to mark the
calendar buffer.  For marking calendar entries, there is no such
thing as the variable diary-list-entries where "other sources of
diary entries" (beyond diary files) could feed there entries to,
which are then all processed to generate the marking of the calendar
buffer.

Am I missing something?

In GNU Emacs 24.3.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.4.2)
 of 2013-10-04 on regnitz
Windowing system distributor `The X.Org Foundation', version 11.0.11103000
System Description:	Ubuntu 12.04.3 LTS