From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#62416: 30.0.50; Symbols skipped in the navigation in ruby-ts-mode Date: Sat, 25 Mar 2023 21:04:52 +0200 Organization: LINKOV.NET Message-ID: <86v8iomzk3.fsf@mail.linkov.net> References: <9cfb677e-2c3b-94f3-e09f-8b231dd9b8f5@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6386"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: =?UTF-8?Q?Bo=C5=A1ko_?= =?UTF-8?Q?Ivani=C5=A1evi=C4=87?= , 62416@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Mar 25 20:19:31 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 1pg9QI-0001SC-W2 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 25 Mar 2023 20:19:30 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pg9Ps-0006IG-9X; Sat, 25 Mar 2023 15:19:04 -0400 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 1pg9Pq-0006Hy-M5 for bug-gnu-emacs@gnu.org; Sat, 25 Mar 2023 15:19:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pg9Pq-0003QJ-EI for bug-gnu-emacs@gnu.org; Sat, 25 Mar 2023 15:19:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pg9Pq-0002Df-8w for bug-gnu-emacs@gnu.org; Sat, 25 Mar 2023 15:19:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 25 Mar 2023 19:19:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62416 X-GNU-PR-Package: emacs Original-Received: via spool by 62416-submit@debbugs.gnu.org id=B62416.16797718858450 (code B ref 62416); Sat, 25 Mar 2023 19:19:02 +0000 Original-Received: (at 62416) by debbugs.gnu.org; 25 Mar 2023 19:18:05 +0000 Original-Received: from localhost ([127.0.0.1]:43521 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pg9Ov-0002CD-9u for submit@debbugs.gnu.org; Sat, 25 Mar 2023 15:18:05 -0400 Original-Received: from relay2-d.mail.gandi.net ([217.70.183.194]:33131) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pg9Ot-0002Bd-Kt for 62416@debbugs.gnu.org; Sat, 25 Mar 2023 15:18:04 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 302BD40002; Sat, 25 Mar 2023 19:17:53 +0000 (UTC) In-Reply-To: <9cfb677e-2c3b-94f3-e09f-8b231dd9b8f5@yandex.ru> (Dmitry Gutov's message of "Fri, 24 Mar 2023 20:41:23 +0200") 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:258621 Archived-At: >> Navigating word forward/backward skips the Ruby symbol in the ruby-ts-mode. >> Adding "simple_symbol" to the treesit-sexp-type-regexp is fixing it. >>   (setq-local treesit-sexp-type-regexp >>               (regexp-opt '("class" >>                             "module" >>                             "method" >>                             "argument_list" >>                             "array" >>                             "hash" >>                             "parenthesized_statements" >>                             "if" >>                             "case" >>                             "when" >>                             "block" >>                             "do_block" >>                             "begin" >>                             "binary" >>                             "simple_symbol" ;; <-- missing >>                             "assignment"))) > > Juri, what do you think? > > In the context of your previous feedback regarding sexp navigation in > ruby-ts-mode. This is fine. But anyway I think in its current state treesit-sexp-type-regexp is underdesigned as noted in https://debbugs.gnu.org/cgi/bugreport.cgi?bug=62238#59 so no tweaking could fix its design flaws. For example, foo = { a: b } when point is on the left curly bracket, 'C-M-f C-M-b' doesn't move back to the original position, etc.