From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.help Subject: Re: Emacs snapshot: free variable warning Date: Fri, 23 Nov 2012 17:37:43 +0400 Message-ID: <87d2z44ezc.fsf@yandex.ru> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1353677892 5925 80.91.229.3 (23 Nov 2012 13:38:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 23 Nov 2012 13:38:12 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Joost Kremers Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Nov 23 14:38:20 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TbtSV-0003Sc-2T for geh-help-gnu-emacs@m.gmane.org; Fri, 23 Nov 2012 14:38:19 +0100 Original-Received: from localhost ([::1]:55644 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbtSK-0001Ti-Ci for geh-help-gnu-emacs@m.gmane.org; Fri, 23 Nov 2012 08:38:08 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:37396) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbtS9-0001Fi-Pq for help-gnu-emacs@gnu.org; Fri, 23 Nov 2012 08:38:01 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TbtS3-0000rM-Ju for help-gnu-emacs@gnu.org; Fri, 23 Nov 2012 08:37:57 -0500 Original-Received: from mail-la0-f41.google.com ([209.85.215.41]:41501) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbtS3-0000qy-C6 for help-gnu-emacs@gnu.org; Fri, 23 Nov 2012 08:37:51 -0500 Original-Received: by mail-la0-f41.google.com with SMTP id m15so5819631lah.0 for ; Fri, 23 Nov 2012 05:37:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=HW3WtXELXjBXXu14h1n/Uh+RyqhMWtcdMjuh96l1q0k=; b=MR9WwL39+5tltQbbapOaCCtS5pLUBNSCEfkHiQW5RjA6tt9vime3wzrA0dTDXhM/re lRP37jmUFxCWQrK4Gr9o75GmjDS2gdrS8L88CLrv4jXgfc8UA9l22xN1LP+kEGgbDrZu a20wYpBy+x+k5cR/PMonDlqL0YdmxX8FlnDt0m6bn6nvE0ycLPk7xDvY55Y65AbmoS8H 3JY4bq+jgU+vWd0Yn2bxZv56tmubK/RMtkrOQDecoa/ptoQboD791RyItqvSLAYp44QI VNbZru6a7dtbwGgEw8uPVClXnmevXGXE2lo5aKMERS+4dFVHjrn+t8vklv2R822o7kLQ y9UA== Original-Received: by 10.112.24.161 with SMTP id v1mr1876629lbf.28.1353677869696; Fri, 23 Nov 2012 05:37:49 -0800 (PST) Original-Received: from SOL ([178.252.98.87]) by mx.google.com with ESMTPS id q2sm2596701lbd.14.2012.11.23.05.37.47 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 23 Nov 2012 05:37:48 -0800 (PST) In-Reply-To: (Joost Kremers's message of "23 Nov 2012 12:11:17 GMT") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (windows-nt) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.215.41 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:87864 Archived-At: Joost Kremers writes: > Hi all, > > After a recent Emacs update (I'm following Damien Cassou's Emacs > snapshot packages at ) one > of my init files started giving me a free variable warning that I never > got before: > > ``` > .emacs.d/mu4e-settings.el:Warning: reference to free variable > `offlineimap-buffer-name' > ``` > > The warning results from a defadvice: > > ``` > (defadvice mu4e-quit (around jk-quit-offlineimap () activate) > "Quit OfflineIMAP when quitting mu4e." > (interactive) > ad-do-it > (signal-process (get-buffer-process (get-buffer offlineimap-buffer-name)) 'SIGUSR2)) > ``` > > If I comment out this defadvice, the warning goes away. > > Anyone know why I'm suddenly getting this warning? It's true that the > variable hasn't been defined yet when the code is loaded, but I have a > defun in the same file which also references this variable but doesn't > produce any warning. Besides, I'm used to getting warnings like this > when compiling code, but not when it's simply loaded... > > If it is intentional (and not some bug introduced with a recent change > to Emacs) is there a way to code the defadvice so that I don't get the > warning? Same here with autopair on Emacs trunk, compiled by myself: ``` .emacs.d/elpa/autopair-20121120.2012/autopair.elc:Warning: reference to free variable `autopair-mode' ``` in *Compile-Log* on startup. Doesn't look like expected behavior.