Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 371DC429E25 for ; Sun, 20 Nov 2011 17:04:40 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6VJG0PyrpLfd for ; Sun, 20 Nov 2011 17:04:39 -0800 (PST) Received: from dmz-mailsec-scanner-3.mit.edu (DMZ-MAILSEC-SCANNER-3.MIT.EDU [18.9.25.14]) by olra.theworths.org (Postfix) with ESMTP id A6F38431FD0 for ; Sun, 20 Nov 2011 17:04:39 -0800 (PST) X-AuditID: 1209190e-b7f4a6d0000008e5-dc-4ec9a3a6b070 Received: from mailhub-auth-3.mit.edu ( [18.9.21.43]) by dmz-mailsec-scanner-3.mit.edu (Symantec Messaging Gateway) with SMTP id 91.91.02277.6A3A9CE4; Sun, 20 Nov 2011 20:04:38 -0500 (EST) Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) by mailhub-auth-3.mit.edu (8.13.8/8.9.2) with ESMTP id pAL14bLd002238; Sun, 20 Nov 2011 20:04:37 -0500 Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) (authenticated bits=0) (User authenticated as amdragon@ATHENA.MIT.EDU) by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id pAL14ala014947 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT); Sun, 20 Nov 2011 20:04:37 -0500 (EST) Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.77) (envelope-from ) id 1RSILf-0002IA-N5; Sun, 20 Nov 2011 20:07:03 -0500 From: Austin Clements To: notmuch@notmuchmail.org Subject: [PATCH] emacs: Avoid unnecessary markers. Date: Sun, 20 Nov 2011 20:07:02 -0500 Message-Id: <1321837622-8755-1-git-send-email-amdragon@mit.edu> X-Mailer: git-send-email 1.7.7.2 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprFIsWRmVeSWpSXmKPExsUixCmqrbts8Uk/g4kbpC2u35zJ7MDo8WzV LeYAxigum5TUnMyy1CJ9uwSujPubV7IXXOCpWL/6H2MD41KuLkZODgkBE4k5LTeYIWwxiQv3 1rN1MXJxCAnsY5TYeH0plLOBUeLeya+MIFVCAieZJB5M54ZIbGaUuHN6KytIgk1AQ2Lb/uVg RSIC0hI7784GinNwMAuoSfzpUgEJCwsYScxdfQFsG4uAqsSaaRvAbF4Be4lnG++yQVyhIDFj yhXGCYy8CxgZVjHKpuRW6eYmZuYUpybrFicn5uWlFuka6+VmluilppRuYgQHgSTfDsavB5UO MQpwMCrx8AoGnvATYk0sK67MPcQoycGkJMq7Y9FJPyG+pPyUyozE4oz4otKc1OJDjBIczEoi vDnOQDnelMTKqtSifJiUNAeLkjjv6h0OfkIC6YklqdmpqQWpRTBZGQ4OJQnefyBDBYtS01Mr 0jJzShDSTBycIMN5gIY/BKnhLS5IzC3OTIfIn2JUlBKHSAiAJDJK8+B6YVH6ilEc6BVhXrWZ QFU8wAiH634FNJgJaPC0tSdABpckIqSkGhg57kW6VFS8spSIaUzvZg1WvnF4wXvhemYN++B/ 3KrX3L3dD1x/qF+U6KCqPMHYe8r0rESmtRrqJhstN0uI6ocfvS9SVt90l2HfVvcvK2eG1Px1 XhTedo7p9zJLo80fN+5cfXOFtMhWoRVc35uOn12s4CN451lxztMkxx75P8wTo5fnn28OZldi Kc5INNRiLipOBAC2TekFrQIAAA== X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 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: Mon, 21 Nov 2011 01:04:40 -0000 This is just cleanup. These markers are all immediately resolved to points by Emacs, so using markers here is just unncessary overhead. --- I originally did this for performance, since Emacs has to scan all un-GC'd markers on every buffer change, but it turns out to matter notmuch. emacs/notmuch.el | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/emacs/notmuch.el b/emacs/notmuch.el index a8e4d62..f15a75b 100644 --- a/emacs/notmuch.el +++ b/emacs/notmuch.el @@ -805,12 +805,12 @@ non-authors is found, assume that all of the authors match." (goto-char (point-max)) (if (/= (match-beginning 1) line) (insert (concat "Error: Unexpected output from notmuch search:\n" (substring string line (match-beginning 1)) "\n"))) - (let ((beg (point-marker))) + (let ((beg (point))) (notmuch-search-show-result date count authors subject tags) - (notmuch-search-color-line beg (point-marker) tag-list) - (put-text-property beg (point-marker) 'notmuch-search-thread-id thread-id) - (put-text-property beg (point-marker) 'notmuch-search-authors authors) - (put-text-property beg (point-marker) 'notmuch-search-subject subject) + (notmuch-search-color-line beg (point) tag-list) + (put-text-property beg (point) 'notmuch-search-thread-id thread-id) + (put-text-property beg (point) 'notmuch-search-authors authors) + (put-text-property beg (point) 'notmuch-search-subject subject) (if (string= thread-id notmuch-search-target-thread) (progn (set 'found-target beg) -- 1.7.7.2