From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.bugs Subject: bug#74277: 29.4; rust-ts-mode doesn't highlight some function calls Date: Sun, 24 Nov 2024 23:34:14 -0800 Message-ID: <89EB0889-DD32-40C2-92E3-8A89ABB6EE37@gmail.com> References: <86bjyookld.fsf@gnu.org> <87r077kl0n.fsf@gmail.com> <87ed3522aj.fsf@gmail.com> <87bjy5yuaz.fsf@gmail.com> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3776.700.51\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7986"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Randy Taylor , Eli Zaretskii , 74277@debbugs.gnu.org, acidbong@tilde.club To: Trevor Arjeski Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Nov 25 08:36:32 2024 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 1tFTe4-0001tT-7U for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 25 Nov 2024 08:36:32 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tFTdn-0001lh-7S; Mon, 25 Nov 2024 02:36:15 -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 1tFTda-0001ka-Ji for bug-gnu-emacs@gnu.org; Mon, 25 Nov 2024 02:36:02 -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 1tFTda-0002Li-8T for bug-gnu-emacs@gnu.org; Mon, 25 Nov 2024 02:36:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:Date:In-Reply-To:From:Mime-Version:To:Subject; bh=lhHYU+OOUtVuHW20Qc+5odGDe/Dm+nNI1P2WeFc6+hI=; b=kovOl5/hJVSMqPA3htHFaZraJAosqpBAZY6l3LKnNEgITQAlBhnN8V9ABrk7rU5tW+C9JwNLPaZN3l2UUSYvYNUnuDNjVZTIZLRs9W6mOIm/o9cXDDty4cuIf0ysACPpZITxrHzqXNLKEhQPFffGngbpIBNGGVbaCYY8NMQ5w2l7QnvgaDrIUoLXFRJiMKx9k7BjSIGsZYYPqXMl/XD6eW8BiC4efm8PWySVKhsIxFqj36gcHbhi82IOASFGzo3w6as4cj5z3QPBU1fg+pwH7nL+oNR38+jjXneiHmLb2kW2mnT++TbqroKZYb7QY5EkQ6qXKTI/HlsEDHce8XlKEQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tFTda-00005t-2e for bug-gnu-emacs@gnu.org; Mon, 25 Nov 2024 02:36:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Yuan Fu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 25 Nov 2024 07:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74277 X-GNU-PR-Package: emacs Original-Received: via spool by 74277-submit@debbugs.gnu.org id=B74277.173252012932766 (code B ref 74277); Mon, 25 Nov 2024 07:36:02 +0000 Original-Received: (at 74277) by debbugs.gnu.org; 25 Nov 2024 07:35:29 +0000 Original-Received: from localhost ([127.0.0.1]:37684 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tFTd3-0008WQ-9F for submit@debbugs.gnu.org; Mon, 25 Nov 2024 02:35:29 -0500 Original-Received: from mail-pf1-f180.google.com ([209.85.210.180]:50227) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tFTd1-0008WG-7a for 74277@debbugs.gnu.org; Mon, 25 Nov 2024 02:35:28 -0500 Original-Received: by mail-pf1-f180.google.com with SMTP id d2e1a72fcca58-724d8422dbaso3016506b3a.0 for <74277@debbugs.gnu.org>; Sun, 24 Nov 2024 23:35:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1732520066; x=1733124866; darn=debbugs.gnu.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=lhHYU+OOUtVuHW20Qc+5odGDe/Dm+nNI1P2WeFc6+hI=; b=kFZFAWyOjg3r52Ouf6hCo3JbJXrdWd9+FVhIC6/wNepL85Q1BUadkfgV9VPh/JKdBe XCJsE2sC6NNbbvrLpJq0mzSw7Zxg++Q10E0J/PFeNdVZSHpD0TzmMTbryISM73Nmd5LQ m9eOZVV/Vfrna1ar6LXI5Q+mKEp4CZaZs+OamcEvacU/8OM+upNhnCOhhf15yinKl9lt cUcorM3rpuQImoOiyA39aqyMjfXKnLVofyaqCq/wpfMBHHMpt0roWGL35HT7pstfTxdy A8S6bgT5250HX70Pyt26TYTmIC4nd0xR8FfO+TjRM5ZdBnvkz6MFfPBtzzfwVE5EXYfU D8iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732520066; x=1733124866; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lhHYU+OOUtVuHW20Qc+5odGDe/Dm+nNI1P2WeFc6+hI=; b=s2XHo9fxkyizeLi5RZNegqqWSC9V9fGraGi8Xc0BXcpBK9IvtrZCpbX5ScI5kagLz2 lIJixBkNUuIJx+Njcz+hj2U5nh0vP0YFCTxPD7ikJRJrVsILNqyPsMdrYN3br880wYob 13/mMEzqXtbS9M3dS0XY5FL9wRRqgP3/D7yYGvQ5pPVk8Im4Mgqd13cs3QnEXTMbTmtC Y03gcl0MRscAQFjhYIu/s42+/En7/7Boiszwj/rPEYengoIjtqPa35pc3+F927HCmhIq N6+tUwl3deYNQB6ZexgJGhAXcZRbC9B3If8Vdyg4rtFLMIMUPn3EGYLgF9qvNBPLn63q cLKQ== X-Forwarded-Encrypted: i=1; AJvYcCWYxW0Z8i6sxYqyv5DvR4wexHUH19sTcgKBxvIg5eWMwrpSSL3B4xla3oL+Mrzn/dtk9iYUWw==@debbugs.gnu.org X-Gm-Message-State: AOJu0YxyrUgNQre9aI4kRyaIpQHfSGSR8l1Km+fPVyjcpUF4ZUXmXg4z H7hasdc+AO4rCxozX051+Xdw6gO2S0inf8nUbdKSr5QdDa5fCyl1 X-Gm-Gg: ASbGncvijyh0ojlq+lBx+mOs3HTP2j1yIOkyqu4gQrDF1j6UxSLaDBDCbzpkJRoGhbx rW0MY/hzeHQOLMcs18Dhncf2vwriqdsgNVVe5QpIpkDfNfeqIpsy8zM+B7QmkntO1NZUW8sa9Xt C87EAGJduzgWFcgRPcyouix2O1iEu+A38RN/C9eERoSjQcETl4m0fpx/k7nXYL/eSaC1ai9Akxf tV0nl5gZA7lXlvs0+Swh8Hj+3i8jedi8J0jCGm7UFVDuMtX12SjmL63bA5Xgz0z58+dNx563w== X-Google-Smtp-Source: AGHT+IE+yjWEngMXoj8dN/fzjdIOkERwi2xO5skPAP2RLbqYvR9jEu4IyJ2wuhOejqlMWy3rHRKG6g== X-Received: by 2002:a05:6a20:4320:b0:1db:e0e5:9109 with SMTP id adf61e73a8af0-1e09e3ba352mr18021938637.4.1732520066126; Sun, 24 Nov 2024 23:34:26 -0800 (PST) Original-Received: from smtpclient.apple ([2601:646:8f81:6120:9db4:d34c:247c:f36b]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2eb0d06299dsm6036420a91.53.2024.11.24.23.34.25 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Nov 2024 23:34:25 -0800 (PST) In-Reply-To: <87bjy5yuaz.fsf@gmail.com> X-Mailer: Apple Mail (2.3776.700.51) 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:295935 Archived-At: > On Nov 23, 2024, at 11:17=E2=80=AFPM, Trevor Arjeski = wrote: >=20 > Yuan Fu writes: >=20 >>> On Nov 21, 2024, at 7:30=E2=80=AFPM, Randy Taylor = wrote: >>>=20 >>> On Wednesday, November 20th, 2024 at 13:22, Trevor Arjeski = wrote: >>>>=20 >>>> Trevor Arjeski tmarjeski@gmail.com writes: >>>>=20 >>>>=20 >>>> I decided to hack around with this a little bit and found that = adding >>>> the following lines partially works: >>>>=20 >>>>=20 >>>> I'm sure there is an issue with solving it this way, I just need = someone >>>> else more experienced to confirm. It is finicky where it turns the >>>> highlighting on and off when you make some code changes, for = example >>>> adding and removing the semi-colon after the macro invocation. >>>=20 >>> Yuan would be the best to answer that. >>=20 >> Using injection (what Emacs calls local parser, same thing) here is = fine, I >> think. As Randy said, tree-sitter doesn=E2=80=99t have a good answer = for macros. If nvim >> uses this workaround (create an injection for the macro and parses it = like >> normal rust code), then it should be fine for us to follow suit. >>=20 >=20 > Any ideas why my crude implementation of the injection "flickers" on = and > off after certain changes? >=20 > Thanks, > Trevor So, after spending a night on this, it appears to be a tree-sitter bug = :( I created an issue here: = https://github.com/tree-sitter/tree-sitter/issues/3962 Yuan