emacs-devel
[Top][All Lists]
Advanced

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

Re: [RFC PATCH] Per-window face support


From: Daniel Colascione
Subject: Re: [RFC PATCH] Per-window face support
Date: Sun, 17 Jun 2018 12:21:03 -0700
User-agent: SquirrelMail/1.4.23 [SVN]

>> I think that ship sailed a long time ago. Almost everyone uses eq for
>> integers, so we should, I think, intern bignums so that things keep
>> working.
>
> But using `eql` is a lot cheaper than hash-consing all bignums
> and floats.

We should consider floats and bignums separately. We get along fine today
with floats the way they are. Bignums are different because we'd be
changing operations that would overflow today into operations that return
bignums, so users would get bignums in places they don't expect. That's
why eq has to keep working.

Anyway, I still think hash-consing bignums is fine, because it's
pay-for-what-you-use. Bignums are expensive anyway, so the overhead of
interning them shouldn't matter all that much. I bet it's cheaper to
intern the occasional bignum than to add branches to every eq in the
codebase.

> I think we should simply start to use `eql` more and phase out `eq`
> little by little.

Sure. Part of the problem is that primitives like assq are hardcoded for
eq-comparison, and other primitives, like assoc, are hardcoded for
equal-comparison. We could add more primitives, but I don't think it'd be
worth the trouble.




reply via email to

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