From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#67117: [PATCH] Tree-sitter: fix an issue when searching subtree backward Date: Wed, 15 Nov 2023 15:21:59 +0200 Message-ID: <83y1ezqhhk.fsf@gnu.org> References: <87h6lruah2.fsf@yandex.ru> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26787"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 67117@debbugs.gnu.org To: Denis Zubarev , Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Nov 15 17:29:15 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1r3IlL-0006YJ-Lp for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 15 Nov 2023 17:29:11 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r3IlH-0002Tn-GG; Wed, 15 Nov 2023 11:29:07 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r3IlF-0002Ro-5b for bug-gnu-emacs@gnu.org; Wed, 15 Nov 2023 11:29:05 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r3IlE-0006Ab-S8 for bug-gnu-emacs@gnu.org; Wed, 15 Nov 2023 11:29:04 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1r3IlD-0002Au-UT for bug-gnu-emacs@gnu.org; Wed, 15 Nov 2023 11:29:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 15 Nov 2023 16:29:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67117 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 67117-submit@debbugs.gnu.org id=B67117.17000656878168 (code B ref 67117); Wed, 15 Nov 2023 16:29:03 +0000 Original-Received: (at 67117) by debbugs.gnu.org; 15 Nov 2023 16:28:07 +0000 Original-Received: from localhost ([127.0.0.1]:53114 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r3IkI-00027a-Lx for submit@debbugs.gnu.org; Wed, 15 Nov 2023 11:28:07 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58120) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r3IQc-0001QS-UT for 67117@debbugs.gnu.org; Wed, 15 Nov 2023 11:07:47 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r3FqL-0003M3-Qb; Wed, 15 Nov 2023 08:22:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=ui7EUguTunVn+uiTlTg4770I3UHS8zk+i3c1emQGPlw=; b=EXFpj2quaBA0 llE+5SGtXhph1faOW82Vw8aMKKbA5jCuaQ98O0nGZ3ci2OPAaipIFkQL0ir2j3X9i82bZt5uPaATu OKqF/CrC6lCELaSvs2/0MZXNFo3Ef2NnvJZ81z2tImnFV0cf4tLLuDjOjwwvbRTQWyVBtMXLQEFyD /KLDOkeaCA83i10QkWEvH9eF3rLmnAneLSwnQWX+/KEdL7gNIwWd98g4gPddmQzfDb9RDdb2knaH0 bFfrMR32xqqDgJ0eokjdMgG5zqTt5SX5zNESvAWifmNVrnGpn9uIYG98oMxOshW5fhfY4Ih05D4n1 fnmIgNLxreS1Zim6TMZ/Pw==; In-Reply-To: <87h6lruah2.fsf@yandex.ru> (message from Denis Zubarev on Sun, 12 Nov 2023 02:38:33 +0300) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:274373 Archived-At: > From: Denis Zubarev > Date: Sun, 12 Nov 2023 02:38:33 +0300 > > Steps to reproduce the issue: > 1. emacs -Q > 2. M-x find-file /tmp/t.py > 3. paste to the buffer > > Temp(1, 2) > > 4. M-x python-ts-mode > 5. Call search-subtree with backward flag > M-x eval-expression (treesit-search-subtree > (treesit--thing-at (point) "call") > (lambda (n) (equal (treesit-node-type n ) "integer")) > t) > It should return the second int node (#), but it returns nil. Yuan, any comments to the patch and the issue in general? Denis, your changes are too large for us to accept them without a copyright assignment. Would you like to start your assignment paperwork at this time, so that we could accept this contribution, and all your future ones? Thanks.