From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: Science to suppress compiler warnings Date: Tue, 2 Jun 2009 16:57:10 -0700 Message-ID: References: <87fxeigro9.wl%xma@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1243987054 22613 80.91.229.12 (2 Jun 2009 23:57:34 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 2 Jun 2009 23:57:34 +0000 (UTC) To: "'Xavier Maillard'" , Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jun 03 01:57:31 2009 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1MBdrG-0003iG-B5 for ged-emacs-devel@m.gmane.org; Wed, 03 Jun 2009 01:57:31 +0200 Original-Received: from localhost ([127.0.0.1]:37781 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MBdrD-0001B9-3X for ged-emacs-devel@m.gmane.org; Tue, 02 Jun 2009 19:57:27 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MBdr7-00019I-3I for emacs-devel@gnu.org; Tue, 02 Jun 2009 19:57:21 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MBdr2-00017A-8A for emacs-devel@gnu.org; Tue, 02 Jun 2009 19:57:20 -0400 Original-Received: from [199.232.76.173] (port=39410 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MBdr2-000177-2X for emacs-devel@gnu.org; Tue, 02 Jun 2009 19:57:16 -0400 Original-Received: from rcsinet12.oracle.com ([148.87.113.124]:28218 helo=rgminet12.oracle.com) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MBdqu-0003Wf-KU; Tue, 02 Jun 2009 19:57:09 -0400 Original-Received: from acsinet15.oracle.com (acsinet15.oracle.com [141.146.126.227]) by rgminet12.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n52Nui4r031855 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 2 Jun 2009 23:56:45 GMT Original-Received: from abhmt002.oracle.com (abhmt002.oracle.com [141.146.116.11]) by acsinet15.oracle.com (Switch-3.3.1/Switch-3.3.1) with ESMTP id n52NvqTR018179; Tue, 2 Jun 2009 23:57:52 GMT Original-Received: from dradamslap1 (/141.144.88.102) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 02 Jun 2009 16:56:53 -0700 X-Mailer: Microsoft Office Outlook 11 Thread-Index: Acnj1xjHTinxinhPScSFcJv0MrE61gABZkTw In-Reply-To: <87fxeigro9.wl%xma@gnu.org> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 X-Source-IP: abhmt002.oracle.com [141.146.116.11] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A09020A.4A25BC46.00B6:SCFSTAT5015188,ss=1,fgs=0 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 1) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:111297 Archived-At: > (eval-when-compile (defvar foo nil)) (eval-when-compile (defvar foo)) You don't give it a value; you just declare it (to the compiler). > Warning: reference to free variable `records-link-menu-map' > Warning: assignment to free variable `records-link-menu-map' > > What is the difference between these two warnings exactly ? The first means the variable is used (referenced) somehow. The second means that it is assigned to. E.g., (setq foo bar) refers to variable `bar', and if it's free, then you get the first warning. (setq bar 5) assigns `bar' a value, which will give you the second warning (if `bar' is free).