[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#6997: Loading w32-fns under X11 signals an error

From: Stefan Monnier
Subject: bug#6997: Loading w32-fns under X11 signals an error
Date: Tue, 14 Sep 2010 11:32:56 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

>> 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.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]