* How does one undo (even temporarily) an defvaralias, giving two distinct variables?
@ 2013-03-12 15:55 Alan Mackenzie
2013-03-12 19:09 ` Achim Gratz
0 siblings, 1 reply; 7+ messages in thread
From: Alan Mackenzie @ 2013-03-12 15:55 UTC (permalink / raw)
To: emacs-devel
Hello, Emacs!
In the CC Mode testing suite, it is necessary that the two variables
`font-lock-reference-face' and `font-lock-constant-face' be distinct.
These variables were made aliases in Emacs 24. I need to separated them
out again.
How does one undo defvaralias and friends?
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-12 15:55 How does one undo (even temporarily) an defvaralias, giving two distinct variables? Alan Mackenzie
@ 2013-03-12 19:09 ` Achim Gratz
2013-03-14 14:31 ` Alan Mackenzie
0 siblings, 1 reply; 7+ messages in thread
From: Achim Gratz @ 2013-03-12 19:09 UTC (permalink / raw)
To: emacs-devel
Alan Mackenzie writes:
> How does one undo defvaralias and friends?
If nothing else works, makunbound should get rid of those symbols so you
can redefine them.
Regards,
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
SD adaptation for Waldorf rackAttack V1.04R1:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-12 19:09 ` Achim Gratz
@ 2013-03-14 14:31 ` Alan Mackenzie
2013-03-14 15:10 ` Thierry Volpiatto
2013-03-14 16:36 ` Stefan Monnier
0 siblings, 2 replies; 7+ messages in thread
From: Alan Mackenzie @ 2013-03-14 14:31 UTC (permalink / raw)
To: Achim Gratz; +Cc: emacs-devel
Hi, Achim.
On Tue, Mar 12, 2013 at 08:09:51PM +0100, Achim Gratz wrote:
> Alan Mackenzie writes:
> > How does one undo defvaralias and friends?
> If nothing else works, makunbound should get rid of those symbols so you
> can redefine them.
makunbound sets the target of the alias unbound, but leaves the alias in
place.
I don't think it's possible to unalias a symbol.
The workaround I've come up with is (defvaralias face (gensym)), which
although it leaves `face' as an alias, at least it points to a different
target.
> Regards,
> Achim.
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-14 14:31 ` Alan Mackenzie
@ 2013-03-14 15:10 ` Thierry Volpiatto
2013-03-14 15:54 ` Andreas Schwab
2013-03-14 16:36 ` Stefan Monnier
1 sibling, 1 reply; 7+ messages in thread
From: Thierry Volpiatto @ 2013-03-14 15:10 UTC (permalink / raw)
To: emacs-devel
Alan Mackenzie <acm@muc.de> writes:
> I don't think it's possible to unalias a symbol.
Probably you could `unintern' it ?
--
Thierry
Get my Gnupg key:
gpg --keyserver pgp.mit.edu --recv-keys 59F29997
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-14 15:10 ` Thierry Volpiatto
@ 2013-03-14 15:54 ` Andreas Schwab
0 siblings, 0 replies; 7+ messages in thread
From: Andreas Schwab @ 2013-03-14 15:54 UTC (permalink / raw)
To: Thierry Volpiatto; +Cc: emacs-devel
Thierry Volpiatto <thierry.volpiatto@gmail.com> writes:
> Alan Mackenzie <acm@muc.de> writes:
>
>> I don't think it's possible to unalias a symbol.
>
> Probably you could `unintern' it ?
That will break every reference to the symbol.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-14 14:31 ` Alan Mackenzie
2013-03-14 15:10 ` Thierry Volpiatto
@ 2013-03-14 16:36 ` Stefan Monnier
2013-03-14 16:52 ` Alan Mackenzie
1 sibling, 1 reply; 7+ messages in thread
From: Stefan Monnier @ 2013-03-14 16:36 UTC (permalink / raw)
To: Alan Mackenzie; +Cc: Achim Gratz, emacs-devel
> The workaround I've come up with is (defvaralias face (gensym)), which
> although it leaves `face' as an alias, at least it points to a different
> target.
BTW don't count on this workaround too much. If it works, it's purely
by accident and might get "fixed" at any time.
Stefan
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How does one undo (even temporarily) an defvaralias, giving two distinct variables?
2013-03-14 16:36 ` Stefan Monnier
@ 2013-03-14 16:52 ` Alan Mackenzie
0 siblings, 0 replies; 7+ messages in thread
From: Alan Mackenzie @ 2013-03-14 16:52 UTC (permalink / raw)
To: Stefan Monnier; +Cc: Achim Gratz, emacs-devel
Hi, Stefan,
On Thu, Mar 14, 2013 at 12:36:37PM -0400, Stefan Monnier wrote:
> > The workaround I've come up with is (defvaralias face (gensym)), which
> > although it leaves `face' as an alias, at least it points to a different
> > target.
> BTW don't count on this workaround too much. If it works, it's purely
> by accident and might get "fixed" at any time.
Sorry, but what might get "fixed"? What is there about that lisp form
which is, strictly speaking, invalid?
> Stefan
--
Alan Mackenzie (Nuremberg, Germany).
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2013-03-14 16:52 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-12 15:55 How does one undo (even temporarily) an defvaralias, giving two distinct variables? Alan Mackenzie
2013-03-12 19:09 ` Achim Gratz
2013-03-14 14:31 ` Alan Mackenzie
2013-03-14 15:10 ` Thierry Volpiatto
2013-03-14 15:54 ` Andreas Schwab
2013-03-14 16:36 ` Stefan Monnier
2013-03-14 16:52 ` Alan Mackenzie
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).