From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.devel Subject: Re: Byte compiler and eval-when-compile Date: Thu, 18 Oct 2012 15:53:02 -0400 Message-ID: References: <87a9vn7lhv.fsf@engster.org> <87626b7d02.fsf@engster.org> <876267zk1u.fsf@engster.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1350589990 15459 80.91.229.3 (18 Oct 2012 19:53:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 18 Oct 2012 19:53:10 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 18 21:53:18 2012 Return-path: Envelope-to: ged-emacs-devel@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 1TOw9a-0003HN-CC for ged-emacs-devel@m.gmane.org; Thu, 18 Oct 2012 21:53:14 +0200 Original-Received: from localhost ([::1]:34165 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TOw9T-0005qk-0k for ged-emacs-devel@m.gmane.org; Thu, 18 Oct 2012 15:53:07 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:49716) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TOw9Q-0005qb-Nm for emacs-devel@gnu.org; Thu, 18 Oct 2012 15:53:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TOw9P-0006cv-E8 for emacs-devel@gnu.org; Thu, 18 Oct 2012 15:53:04 -0400 Original-Received: from fencepost.gnu.org ([208.118.235.10]:33015) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TOw9P-0006cr-Ab for emacs-devel@gnu.org; Thu, 18 Oct 2012 15:53:03 -0400 Original-Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1TOw9O-0005i6-L6; Thu, 18 Oct 2012 15:53:02 -0400 X-Spook: SAPO Leitrim beanpole Baranyi Manfurov Indigo Cocaine ISEC X-Ran: LfNCqpE0Z8"[]UX}Bda=M]T_gHC"oYmN>!;RL[}14P\W)uh(X&G[isSO]?Qg(R$vbOU|B* X-Hue: magenta X-Attribution: GM In-Reply-To: <876267zk1u.fsf@engster.org> (David Engster's message of "Thu, 18 Oct 2012 20:55:57 +0200") User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 208.118.235.10 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:154421 Archived-At: David Engster wrote: > Could you maybe take a look at the end of eieio.el? I don't understand > why the compiler warns that `eieio-update-lisp-imenu-expression' is > undefined (he actually always did that, not only since your last > change). I'm also not sure what's the fix here - why did you wrap the > check for (boundp 'lisp-imenu-generic-expression) in an > `eval-when-compile'? The byte-compiler is not that smart and doesn't fully recognize defuns that are not at top-level. This one is "hidden" inside an if. You could eval-and-compile the whole thing (defun and all) to make the warning go away. But lisp-imenu-generic-expression is defined in every Emacs since at least 21.1, so I don't see the point of the if, unless it's an XEmacs thing, in which case featurep 'xemacs can be cleaner.