[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved positio
From: |
Eli Zaretskii |
Subject: |
bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position |
Date: |
Sun, 26 Mar 2023 08:20:48 +0300 |
> From: Liu Hui <liuhui1610@gmail.com>
> Date: Sun, 26 Mar 2023 09:26:22 +0800
> Cc: 62413@debbugs.gnu.org
>
> > But now testing save-place-abbreviate-file-names here should be
> > redundant, right?
> >
> > Also, I think we should first test buffer-file-name, and only after
> > that its abbreviated variant.
>
> I don't think so. Consider the following case:
>
> - open file A and then close the buffer:
> (buffer-file-name . position1) is saved in save-place-alist
>
> - then set save-place-abbreviate-file-names to t
>
> - open file A, scroll the buffer and close it:
> (abbreviated-file-name . position2) is saved
>
> - open file A again, and the point will be at position1 if
> buffer-file-name is tested first. But I would expect the point is at
> position2.
Ugh! This feature was not thought out well enough when it was
introduced: if the user changes the value half-way through a session,
the history will record visited files twice, under 2 different
file-name formats and with different places recorded. I think
changing the value of save-place-abbreviate-file-names should rewrite
the entire alist in the selected format.
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Liu Hui, 2023/03/24
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Eli Zaretskii, 2023/03/25
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Liu Hui, 2023/03/25
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Eli Zaretskii, 2023/03/25
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Liu Hui, 2023/03/25
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position,
Eli Zaretskii <=
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Liu Hui, 2023/03/28
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Eli Zaretskii, 2023/03/28
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Liu Hui, 2023/03/29
- bug#62413: 29.0.60; [PATCH] save-place-mode cannot restore saved position, Eli Zaretskii, 2023/03/30