GNU bug report logs - #59497
29.0.50; Wrong type argument: number-or-marker-p, nil when enabling Tree Sitter in empty buffer

Previous Next

Package: emacs;

Reported by: Daniel Martín <mardani29 <at> yahoo.es>

Date: Wed, 23 Nov 2022 00:39:02 UTC

Severity: normal

Found in version 29.0.50

Done: Yuan Fu <yuf011 <at> ucsd.edu>

Bug is archived. No further changes may be made.

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Daniel Martín <mardani29 <at> yahoo.es>
To: bug-gnu-emacs <at> gnu.org
Subject: 29.0.50; Wrong type argument: number-or-marker-p, nil when enabling
 Tree Sitter in empty buffer
Date: Wed, 23 Nov 2022 01:37:41 +0100
Steps to reproduce:

emacs -Q
C-x b foo RET
M-x python-ts-mode RET

Wrong type argument: number-or-marker-p is thrown.

The bug seems to be in treesit-ready-p, specifically at:

(> (position-bytes (1- (point-max))) treesit-max-buffer-size)

This check fails if the buffer is empty.




This bug report was last modified 2 years and 260 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.