From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Yuri D'Elia Newsgroups: gmane.emacs.devel Subject: "reference to free variable" only during initialization Date: Tue, 17 Jan 2017 00:00:22 +0100 Message-ID: <87ziiq4nll.fsf@wavexx.thregr.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1484607723 14381 195.159.176.226 (16 Jan 2017 23:02:03 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 16 Jan 2017 23:02:03 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jan 17 00:01:57 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cTGHk-00038L-BU for ged-emacs-devel@m.gmane.org; Tue, 17 Jan 2017 00:01:56 +0100 Original-Received: from localhost ([::1]:60246 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTGHp-0006XI-3B for ged-emacs-devel@m.gmane.org; Mon, 16 Jan 2017 18:02:01 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47535) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTGH3-0006UG-Hg for emacs-devel@gnu.org; Mon, 16 Jan 2017 18:01:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cTGGz-0000x8-Na for emacs-devel@gnu.org; Mon, 16 Jan 2017 18:01:13 -0500 Original-Received: from [195.159.176.226] (port=40013 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cTGGz-0000wC-Gf for emacs-devel@gnu.org; Mon, 16 Jan 2017 18:01:09 -0500 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1cTGGh-0006N0-9U for emacs-devel@gnu.org; Tue, 17 Jan 2017 00:00:51 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 31 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:gsS6GzFE/KOI9qk3L18EcRSa404= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:211340 Archived-At: I have an oddball warning that I have an hard time debugging. I upgraded to emacs 25.1.1 on a debian desktop recently, and started to get: Warning (bytecomp): reference to free variable ‘isearchp-reg-beg’ during startup. The warning is generated by requiring modeline-posn.el[1], which is using ``isearchp-reg-beg`` (actually defvar-ed early on) inside a defadvice form. Is this expected? Warning aside, the intriguing part is that the warning /only/ occurs when (require 'modeline-posn) is evaluated in my ~/.emacs, but is not emitted instead when doing the "allegedly" equivalent: emacs -q -l ~/.emacs even when ~/.emacs itself only contains: (add-to-list 'load-path "path-to-modeline.el") (require 'modeline-posn) or when simply doing an eval in a fresh emacs -q session The remaining difference is that emacs -q is skipping debian's system startup. But I cannot think of something that could influence the generation of a bytecomp warning. Any pointer before going further? [1] https://www.emacswiki.org/emacs/modeline-posn.el