From: Tomi Ollila Date: Wed, 26 Aug 2015 20:07:05 +0000 (+0300) Subject: [PATCH 1/2] emacs: add defsubst notmuch-address--message-insinuated X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=fed3e592b222a911a43292cb5411b940726abf84;p=notmuch-archives.git [PATCH 1/2] emacs: add defsubst notmuch-address--message-insinuated --- diff --git a/3e/9d8d1a106c4fcca4846188a19486343fba6e54 b/3e/9d8d1a106c4fcca4846188a19486343fba6e54 new file mode 100644 index 000000000..4f12ef13a --- /dev/null +++ b/3e/9d8d1a106c4fcca4846188a19486343fba6e54 @@ -0,0 +1,75 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 114426DE0275 + for ; Wed, 26 Aug 2015 13:08:42 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: 0.254 +X-Spam-Level: +X-Spam-Status: No, score=0.254 tagged_above=-999 required=5 tests=[AWL=0.794, + RP_MATCHES_RCVD=-0.55, T_HEADER_FROM_DIFFERENT_DOMAINS=0.01] + autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id vFR85zXaCA0f for ; + Wed, 26 Aug 2015 13:08:39 -0700 (PDT) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by arlo.cworth.org (Postfix) with ESMTP id D7BD56DE0140 + for ; Wed, 26 Aug 2015 13:08:38 -0700 (PDT) +Received: by guru.guru-group.fi (Postfix, from userid 501) + id 101FB1000E6; Wed, 26 Aug 2015 23:07:08 +0300 (EEST) +From: Tomi Ollila +To: notmuch@notmuchmail.org +Subject: [PATCH 1/2] emacs: add defsubst notmuch-address--message-insinuated +Date: Wed, 26 Aug 2015 23:07:05 +0300 +Message-Id: <1440619626-18768-1-git-send-email-tomi.ollila@iki.fi> +X-Mailer: git-send-email 2.0.0 +Cc: tomi.ollila@iki.fi +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.18 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Wed, 26 Aug 2015 20:08:42 -0000 + +This "inline function" is currently used in +notmuch-address-message-insinuate (to not enable address completion if +it is already enabled). In some functions later this will be called +to know whether address completion can be used there, too. +--- + +Previous version of this 2-patch series is at +id:1423229911-14784-1-git-send-email-too@guru.guru-group.fi + + emacs/notmuch-address.el | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/emacs/notmuch-address.el b/emacs/notmuch-address.el +index fde3c1b2b861..6c93b2a7a820 100644 +--- a/emacs/notmuch-address.el ++++ b/emacs/notmuch-address.el +@@ -54,8 +54,11 @@ (defvar notmuch-address-message-alist-member + + (defvar notmuch-address-history nil) + ++(defsubst notmuch-address--message-insinuated () ++ (memq notmuch-address-message-alist-member message-completion-alist)) ++ + (defun notmuch-address-message-insinuate () +- (unless (memq notmuch-address-message-alist-member message-completion-alist) ++ (unless (notmuch-address--message-insinuated) + (setq message-completion-alist + (push notmuch-address-message-alist-member message-completion-alist)))) + +-- +2.0.0 +