emacs-devel
[Top][All Lists]
Advanced

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

Re: master 3fc859d: Go back to iso-2022-7bit for titdic-cnv.el again


From: Eli Zaretskii
Subject: Re: master 3fc859d: Go back to iso-2022-7bit for titdic-cnv.el again
Date: Mon, 06 Jan 2020 19:07:59 +0200

> From: Stefan Monnier <address@hidden>
> Date: Sun, 05 Jan 2020 15:55:56 -0500
> Cc: Paul Eggert <address@hidden>
> 
> FWIW, when I converted it to utf-8, I (tried to) make sure the generated
> .elc files were bit-for-bit identical.  Looking at the URL you mention,
> I don't see any concrete example of a problem introduced by utf-8.

I'm not saying the code is wrong.  But surely, you'll agree that code
like this:

    (let ((foo ("x" "foo" "foo")))
      (if baz (nth 1 foo) (nth 2 foo)))

just wastes CPU cycles (and some memory), and does little otherwise?

When titdic-cnv.el was encoded in ISO-2022, the 2 "foo"s belonged to 2
different charsets, so the result was less trivial.  (And yes, a
couple of string pairs are not really identical, but almost all of
them are, so treating all of them as different just doesn't look right
to me.)

If the charset properties are not important here at all (I'm not sure
yet), then we should rewrite that code not to "select" one of 2
identical strings.  And if the charset is important, we should still
have only one copy of each string, but propertize it with the charset
selected according to the big5-p flag.



reply via email to

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