emacs-devel
[Top][All Lists]
Advanced

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

Re: byte-opt.el addition - optimize list of compile-time constants


From: Andreas Schwab
Subject: Re: byte-opt.el addition - optimize list of compile-time constants
Date: Thu, 09 Dec 2004 11:34:13 +0100
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux)

Paul Pogonyshev <address@hidden> writes:

> Zack Weinberg wrote:
>> I seriously wonder how much would break if this optimization were
>> implemented for 'list'.  My suspicion is that people don't commonly
>> apply 'eq' to lists in the first place.
>
> You are very wrong here.  While it will hardly break sane code,
> `eq' is _very_ often applied to cons cells, e.g. lists.

Also 'list' is sometimes intentionally used to create a new cons that can
be changed by side effect.  If it were optimized to a constant the side
effect would now change a literal.

Andreas.

-- 
Andreas Schwab, SuSE Labs, address@hidden
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




reply via email to

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