From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#6997: Loading w32-fns under X11 signals an error Date: Tue, 14 Sep 2010 11:32:56 +0200 Message-ID: References: <8362ya5cwu.fsf@gnu.org> <831v8x6fb2.fsf@gnu.org> <83hbht4q7k.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1284457242 23483 80.91.229.12 (14 Sep 2010 09:40:42 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 14 Sep 2010 09:40:42 +0000 (UTC) Cc: 6997@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Sep 14 11:40:41 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OvS0G-0001Dw-JM for geb-bug-gnu-emacs@m.gmane.org; Tue, 14 Sep 2010 11:40:40 +0200 Original-Received: from localhost ([127.0.0.1]:60389 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OvS0F-0001Ve-QV for geb-bug-gnu-emacs@m.gmane.org; Tue, 14 Sep 2010 05:40:39 -0400 Original-Received: from [140.186.70.92] (port=43142 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OvS07-0001VZ-DS for bug-gnu-emacs@gnu.org; Tue, 14 Sep 2010 05:40:32 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OvS06-00050L-GH for bug-gnu-emacs@gnu.org; Tue, 14 Sep 2010 05:40:31 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:45885) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OvS06-00050H-Dz for bug-gnu-emacs@gnu.org; Tue, 14 Sep 2010 05:40:30 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1OvRqw-0003tb-Ed; Tue, 14 Sep 2010 05:31:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 14 Sep 2010 09:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6997 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 6997-submit@debbugs.gnu.org id=B6997.128445664914969 (code B ref 6997); Tue, 14 Sep 2010 09:31:02 +0000 Original-Received: (at 6997) by debbugs.gnu.org; 14 Sep 2010 09:30:49 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OvRqi-0003tO-LJ for submit@debbugs.gnu.org; Tue, 14 Sep 2010 05:30:49 -0400 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OvRqf-0003tH-SV for 6997@debbugs.gnu.org; Tue, 14 Sep 2010 05:30:46 -0400 Original-Received: from ceviche.home (vpn-132-204-232-49.acd.umontreal.ca [132.204.232.49]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id o8E9Wu1D021159; Tue, 14 Sep 2010 05:32:57 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id 19C966637B; Tue, 14 Sep 2010 11:32:56 +0200 (CEST) In-Reply-To: <83hbht4q7k.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 13 Sep 2010 17:29:19 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3621=0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Tue, 14 Sep 2010 05:31:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:40159 Archived-At: >> I'm not sure exactly what you're trying to argue here. > I'm not trying to argue at all, just trying to understand what you > want to be done about w32-fns.el. I'd like w32-fns.el to be harmless even on platforms where it's normally not loaded. I understand it's not a very high priority item. > But many .el files have top-level expressions other than defun and > defvar. These don't just define functions and variables, they > actually change the behavior. Actually, very few have toplevel expressions that modify the behavior, nowadays. The main remaining ones are the preloaded files, so the real problematic ones are most likely the files that are preloaded on some configs and not on others. > w32-fns.el does that as well, but it is not the only one. > I understand that you want all these top-level expressions be > conditioned by w32? They can be conditioned on system-type, yes, tho it doesn't have to be a toplevel test: the way w32-convert-standard-filename does it is fine as well. > How about teaching your code not to load any file that has w32 (or > dos, or ns, for that matter) in its name? Of course, that's pretty much the workaround I'm using right now, but it's still just a workaround. I may very well want to complete w32-* names under GNU/Linux after all. > Or perhaps we should have a list of platform-specific .el files that > are not "safe" for loading on other platforms? Actually, we should be aiming towards a code-base where Emacs can be built with w32 and X11 and ns backends at the same time (after all w32 platforms can run X11 apps as well and GNUstep works on top of X11). This is longish term and I don't necessarily want you to start working on it, but rather it should be used as a guide for how best to solve problems we encounter. Stefan