From: "Michaël Cadilhac" <michael@cadilhac.name>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 65877@debbugs.gnu.org
Subject: bug#65877: 29.1; line-number-at-pos crashes with args-out-of-range when ran using emacsclient
Date: Tue, 12 Sep 2023 10:59:08 -0500 [thread overview]
Message-ID: <CADt3fpP02hAwwHHL1zsiC43aLCoPv0WpDHSCP_X2CvZQRhZ4eg@mail.gmail.com> (raw)
In-Reply-To: <83o7i7pr44.fsf@gnu.org>
On Tue, Sep 12, 2023 at 6:29 AM Eli Zaretskii <eliz@gnu.org> wrote:
> This is a cockpit error, not a bug. The doc string of
> line-number-at-pos says:
>
> line-number-at-pos is a built-in function in ‘src/fns.c’.
>
> (line-number-at-pos &optional POSITION ABSOLUTE)
>
> Return the line number at POSITION in the current buffer.
> ^^^^^^^^^^^^^^^^^^^^^
>
> So the correct form to evaluate is this:
>
> $ emacsclient -e "(with-current-buffer (window-buffer) (line-number-at-pos (window-start)))"
Fantastic, thanks for your help, and apologies for the noise.
next prev parent reply other threads:[~2023-09-12 15:59 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-11 21:07 bug#65877: 29.1; line-number-at-pos crashes with args-out-of-range when ran using emacsclient Michaël Cadilhac
2023-09-12 11:28 ` Eli Zaretskii
2023-09-12 15:59 ` Michaël Cadilhac [this message]
2023-09-12 16:43 ` Eli Zaretskii
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CADt3fpP02hAwwHHL1zsiC43aLCoPv0WpDHSCP_X2CvZQRhZ4eg@mail.gmail.com \
--to=michael@cadilhac.name \
--cc=65877@debbugs.gnu.org \
--cc=eliz@gnu.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).