[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#70784: Abolish string resizing
From: |
Stefan Monnier |
Subject: |
bug#70784: Abolish string resizing |
Date: |
Sun, 05 May 2024 22:41:54 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
>> The Elisp ability to resize strings is high-cost, low-benefit, so we
>> should abolish it.
> What is the improvement to be had by "abolishing" this immemorial
> feature?
Actually, it's not "immemorial", it's just old:
commit 3c9de1afcde82a99137721436c822059cce79b5b
Author: Kenichi Handa <handa@gnu.org>
Date: Fri Jul 21 06:45:30 2000 +0000
(Faset): Allow storing any multibyte character in a string. Convert
unibyte string to multibyte if necessary.
IOW, since Emacs-21.1.
As for improvements, like a lot of refactoring and maintenance work,
there isn't any immediate benefit. But it's a "feature" which is *very*
rarely used (thank god: it makes a notionally constant time operation
take time proportional to the size of the string, so if it were used
often we would have heard complaints about the poor performance) and
which imposes pretty significant implementation constraints, so it's
definitely detrimental to long term evolution.
Stefan
- bug#70784: Abolish string resizing, (continued)
bug#70784: Abolish string resizing, Po Lu, 2024/05/05
bug#70784: Abolish string resizing,
Stefan Monnier <=
bug#70784: Abolish string resizing, Eli Zaretskii, 2024/05/06
bug#70784: Abolish string resizing, Richard Stallman, 2024/05/08