From: "Vincent Belaïche" <vincent.belaiche@gmail.com>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: "Stefan Kangas" <stefan@marxist.se>,
"Vincent Belaïche" <vincentbelaiche@orange.fr>,
5852@debbugs.gnu.org, "Göran Uddeborg" <goeran@uddeborg.se>
Subject: bug#5852: 23.1; Incorrect references in ses-mode
Date: Sun, 25 Jul 2021 07:56:35 +0200 [thread overview]
Message-ID: <CAPAOBV-OLXb7rL56ry8bSwTMMu89SY3CkeVVQ09NdS5B49qDYw@mail.gmail.com> (raw)
In-Reply-To: <CAPAOBV8OCo660-4gu6KRoiq2TEkp_FoYOHpVhKwESBtqEnd-1Q@mail.gmail.com>
On more significant difference between the function bug-5852 and the
example is the the initial size is (3 . 3) instead of (1. 1). This is
because I speculated that only the last row insertion (C-o) plays a
role.
V.
Le dim. 25 juil. 2021 à 07:48, Vincent Belaïche
<vincent.belaiche@gmail.com> a écrit :
>
> Just to add something : reading again SES code, and (info "(elisp)
> Command Overview") I am a bit skeptical about the explanation in my
> previous email.
> It seems that only key strokes are queue, but command execution and
> post command hook are in sequence, so not done concurrently.
> I wrote this function to try to reproduce the bug, and on my office PC
> it does not reproduce it:
>
> (defun bug-5852 ();;---
> "Check no irrelevant reference is created when a row is inserted and
> a formula is yanked"
> (interactive);;---
> (let ((ses-initial-size '(3 . 3)))
> (with-temp-buffer
> (ses-mode)
> (dolist (val '(
> (ses-edit-cell 0 1 1)
> (ses-edit-cell 1 0 2)
> (ses-edit-cell 1 1 (+ B1 A2))
> (ses-edit-cell 2 0 3)
> (ses-edit-cell 2 1 (+ B2 A3))
> (ses-jump A3)
> (ses-insert-row 1)
> (ses-edit-cell 2 0 4)
> (ses-jump B2)
> ))
> (apply 'funcall-interactively val)
> (ses-command-hook))
> (let ((beg (point-marker)))
> (ses-jump 'C2) ; C-n
> (copy-region-as-kill beg (point) nil)
> (set-marker beg nil))
> (dolist (val '(
> (ses-jump B3)
> (yank)
> (ses-jump B4)
> (yank)
> ))
> (apply 'funcall-interactively val)
> (ses-command-hook))
> (ses-repair-cell-reference-all)
> )))
>
> Please note that the main difference with the provided example is that
> motion is done with ses-jump, and not with motion commands. Also the
> save to keyring is not done interatively.
> V.
>
> Le sam. 24 juil. 2021 à 23:46, Vincent Belaïche
> <vincent.belaiche@gmail.com> a écrit :
> >
> > Hello Lars,
> >
> > Sorry for not making any feedback for so long, actually I was just
> > distracted by some other business, and I somewhat had forgotten about
> > it.
> >
> > I suspect a race condition between the post command hook and the next
> > command. That is to say when one yanks the fomula (the first yank),
> > one relocates the reference but for this one uses current references
> > that have not yet been relocated because the previous post-command
> > hook execution is not yet over.
> >
> > The bug does not show every time I do the experiment. I tried this
> > morning with my office PC which is a fast machine, and it proved out
> > quite hard to reproduce, even when I launched some big C program
> > compilation in parallel to eat the mips.
> >
> > Next week I will do some experiment with my home PC which is quite
> > quite slower, and I make some feedback. Unfortunateless both machine
> > do not have the same emacs version, but anyway all changes in SES
> > since the version on my home PC are not related to this bug, so
> > nevertheless that will be a good indication whether my guess is
> > correct.
> >
> > V.
> >
> > Le dim. 18 juil. 2021 à 15:37, Lars Ingebrigtsen <larsi@gnus.org> a écrit :
> > >
> > > Vincent Belaïche <vincentbelaiche@orange.fr> writes:
> > >
> > > > I will investigate why and feed back once I have a better idea of what
> > > > is happening.
> > >
> > > Hi,
> > >
> > > this was a year ago. Did you make any progress on this issue?
> > >
> > > --
> > > (domestic pets only, the antidote for overdose, milk.)
> > > bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2021-07-25 5:56 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-07 16:15 bug#5852: 23.1; Incorrect references in ses-mode Göran Uddeborg
2020-02-29 3:14 ` Stefan Kangas
2020-02-29 20:13 ` Vincent Belaïche
2021-07-18 13:36 ` Lars Ingebrigtsen
2021-07-24 21:46 ` Vincent Belaïche
2021-07-25 5:48 ` Vincent Belaïche
2021-07-25 5:56 ` Vincent Belaïche [this message]
2021-07-25 6:17 ` Vincent Belaïche
2021-07-25 6:18 ` Vincent Belaïche
2021-07-25 6:32 ` Vincent Belaïche
2021-07-25 6:38 ` Vincent Belaïche
2021-07-25 6:44 ` Lars Ingebrigtsen
2021-07-25 17:27 ` Vincent Belaïche
2021-07-30 21:01 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-08-02 21:02 ` Vincent Belaïche
2023-12-29 12:03 ` Vincent Belaïche
2023-12-29 12:36 ` Stefan Kangas
2023-12-29 14:19 ` Eli Zaretskii
2023-12-29 15:19 ` Vincent Belaïche
2023-12-29 22:01 ` Göran Uddeborg
2024-01-14 13:17 ` Mattias Engdegård
2024-01-14 13:35 ` Mattias Engdegård
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAPAOBV-OLXb7rL56ry8bSwTMMu89SY3CkeVVQ09NdS5B49qDYw@mail.gmail.com \
--to=vincent.belaiche@gmail.com \
--cc=5852@debbugs.gnu.org \
--cc=goeran@uddeborg.se \
--cc=larsi@gnus.org \
--cc=stefan@marxist.se \
--cc=vincentbelaiche@orange.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.