Michael Haggerty wrote:

> In fact, all struct store instances are upcasts of struct imap_store
> anyway, so stop making the distinction.


It is tempting to fold "struct store" into "struct imap_store" at the same
time, as in

        struct imap_store {
                struct {
                        struct store_conf *conf; /* foreign */

                        /* currently open mailbox */
                        const char *name; /* foreign! maybe preset? */
                        char *path; /* own */
                        struct message *msgs; /* own */
                        int uidvalidity;
                        unsigned char opts; /* maybe preset? */
                        /* note that the following do _not_ reflect stats from 
msgs, but mailbox totals */
                        int count; /* # of messages */
                        int recent; /* # of recent messages - don't trust this 
beyond the initial read */
                } gen;
                int uidvalidity;
                struct imap *imap;
                const char *prefix;
                unsigned /*currentnc:1,*/ trashnc:1;

to help the reader verify that objects of type "struct store" are not
used except through the gen field of imap_store after this change.
But verifying directly worked fine, so never mind. ;-)
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to