* bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master
@ 2016-07-10 23:33 Clément Pit--Claudel
2016-07-11 14:20 ` Paul Eggert
2016-07-11 14:21 ` Eli Zaretskii
0 siblings, 2 replies; 5+ messages in thread
From: Clément Pit--Claudel @ 2016-07-10 23:33 UTC (permalink / raw)
To: 23938; +Cc: Paul Eggert
[-- Attachment #1.1: Type: text/plain, Size: 1449 bytes --]
Hi all,
Running the following in Emacs 24 and 25-rc pops a buffer displaying "bd". On master, it displays "b" and "d" on top of each other.
(with-current-buffer (get-buffer-create "*test*")
(erase-buffer)
(fundamental-mode)
(insert "test")
(compose-region (point-min) (point-max) '(?b (Br . Bl) ?d))
(pop-to-buffer (current-buffer)))
Bisecting points to the following commit:
237244bbd5ce753bcdf79634561de515bd76c687 is the first bad commit
commit 237244bbd5ce753bcdf79634561de515bd76c687
Author: Paul Eggert <eggert@cs.ucla.edu>
Date: Mon May 30 16:09:25 2016 -0700
Omit IF_LINT code that no longer seems needed
Nowadays GCC is smarter, or the Emacs code has mutated, or both,
and now is as good a time as any to remove uses of IF_LINT that
now seem to be unnecessary.
(...)
The small test case is courtesy of Artur; we both noticed the issue while using his (awesome) ‘nameless’ package; see https://github.com/Malabarba/Nameless/issues/15 for details on the issue that prompted the investigation.
Cheers,
Clément.
In GNU Emacs 25.1.50.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.10.8)
of 2016-06-26 built on clem-w50-mint
Repository revision: 431437b6593320dc5a7a8aac9c911c778a656117
Windowing system distributor 'The X.Org Foundation', version 11.0.11501000
System Description: Linux Mint 17.3 Rosa
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master
2016-07-10 23:33 bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master Clément Pit--Claudel
@ 2016-07-11 14:20 ` Paul Eggert
2016-07-11 14:21 ` Eli Zaretskii
1 sibling, 0 replies; 5+ messages in thread
From: Paul Eggert @ 2016-07-11 14:20 UTC (permalink / raw)
To: Clément Pit--Claudel, 23938-done
[-- Attachment #1: Type: text/plain, Size: 190 bytes --]
Thanks for tracking that bug down and for the reproducible test case. It
was a typo in that refactoring commit; sorry about that. I installed the
attached patch into master to fix things.
[-- Attachment #2: 0001-Fix-composition-bug-caused-by-off-by-1-typo.patch --]
[-- Type: text/x-patch, Size: 888 bytes --]
From 8cb5ab5cf48362ea64c6463a8aabc4892c5352f7 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Mon, 11 Jul 2016 16:14:33 +0200
Subject: [PATCH] Fix composition bug caused by off-by-1 typo
* src/xdisp.c (x_produce_glyphs): Fix off-by-one typo when
computing composition glyph (Bug#23938).
---
src/xdisp.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/xdisp.c b/src/xdisp.c
index d5ffb25..14d6f8f 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -27369,8 +27369,8 @@ x_produce_glyphs (struct it *it)
eassume (0 < glyph_len); /* See Bug#8512. */
do
- c = COMPOSITION_GLYPH (cmp, --glyph_len);
- while (c == '\t' && 0 < glyph_len);
+ c = COMPOSITION_GLYPH (cmp, glyph_len - 1);
+ while (c == '\t' && 0 < --glyph_len);
bool right_padded = glyph_len < cmp->glyph_len;
for (i = 0; i < glyph_len; i++)
--
2.5.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master
2016-07-10 23:33 bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master Clément Pit--Claudel
2016-07-11 14:20 ` Paul Eggert
@ 2016-07-11 14:21 ` Eli Zaretskii
2016-07-11 14:36 ` Paul Eggert
1 sibling, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2016-07-11 14:21 UTC (permalink / raw)
To: Clément Pit--Claudel; +Cc: eggert, 23938-done
> From: Clément Pit--Claudel <clement.pitclaudel@live.com>
> Date: Mon, 11 Jul 2016 01:33:38 +0200
> Cc: Paul Eggert <eggert@cs.ucla.edu>
>
> Running the following in Emacs 24 and 25-rc pops a buffer displaying "bd". On master, it displays "b" and "d" on top of each other.
>
> (with-current-buffer (get-buffer-create "*test*")
> (erase-buffer)
> (fundamental-mode)
> (insert "test")
> (compose-region (point-min) (point-max) '(?b (Br . Bl) ?d))
> (pop-to-buffer (current-buffer)))
>
> Bisecting points to the following commit:
>
> 237244bbd5ce753bcdf79634561de515bd76c687 is the first bad commit
> commit 237244bbd5ce753bcdf79634561de515bd76c687
> Author: Paul Eggert <eggert@cs.ucla.edu>
> Date: Mon May 30 16:09:25 2016 -0700
>
> Omit IF_LINT code that no longer seems needed
>
> Nowadays GCC is smarter, or the Emacs code has mutated, or both,
> and now is as good a time as any to remove uses of IF_LINT that
> now seem to be unnecessary.
> (...)
Thanks, fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master
2016-07-11 14:21 ` Eli Zaretskii
@ 2016-07-11 14:36 ` Paul Eggert
2016-07-11 15:04 ` Eli Zaretskii
0 siblings, 1 reply; 5+ messages in thread
From: Paul Eggert @ 2016-07-11 14:36 UTC (permalink / raw)
To: Eli Zaretskii, Clément Pit--Claudel; +Cc: 23938-done
On 07/11/2016 04:21 PM, Eli Zaretskii wrote:
> Thanks, fixed.
Amusingly enough, you and I independently installed exactly the same
code patch, byte-for-byte, nearly simultaneously. There is no difference
between commits 4ba2946369cb19dfeb258839add0658c742c12a1 and
10cfb736e2d32bd2604dc93a979ce136473b5944, and Git silently merged the
two when you merged your commit into master. I don't know whether to
worry about our duplicative work or to re-tell the famous war story
about Ritchie and Thompson; see, for example, page 4 of:
McIlroy MD. Remarks for Japan Prize award ceremony for Dennis Ritchie.
2011-05-19, Murray Hill, NJ. http://www.cs.dartmouth.edu/~doug/dmr.pdf
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master
2016-07-11 14:36 ` Paul Eggert
@ 2016-07-11 15:04 ` Eli Zaretskii
0 siblings, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2016-07-11 15:04 UTC (permalink / raw)
To: Paul Eggert; +Cc: clement.pitclaudel, 23938
> Cc: 23938-done@debbugs.gnu.org
> From: Paul Eggert <eggert@cs.ucla.edu>
> Date: Mon, 11 Jul 2016 16:36:19 +0200
>
> On 07/11/2016 04:21 PM, Eli Zaretskii wrote:
> > Thanks, fixed.
>
> Amusingly enough, you and I independently installed exactly the same
> code patch, byte-for-byte, nearly simultaneously. There is no difference
> between commits 4ba2946369cb19dfeb258839add0658c742c12a1 and
> 10cfb736e2d32bd2604dc93a979ce136473b5944, and Git silently merged the
> two when you merged your commit into master.
Yep. It happens.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2016-07-11 15:04 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-10 23:33 bug#23938: Commit 237244bbd5ce753bcdf79634561de515bd76c687 broke display of composed characters on master Clément Pit--Claudel
2016-07-11 14:20 ` Paul Eggert
2016-07-11 14:21 ` Eli Zaretskii
2016-07-11 14:36 ` Paul Eggert
2016-07-11 15:04 ` Eli Zaretskii
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.