From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jostein =?UTF-8?Q?Kj=C3=B8nigsen?= Newsgroups: gmane.emacs.bugs Subject: bug#61302: 29.0.60; rust-ts-mode does not show function-invocation on field-properties Date: Sun, 05 Feb 2023 22:52:46 +0100 Message-ID: <5bd2f9f0-39d5-4d6b-815d-eda20d366441@app.fastmail.com> References: <6209c097-0369-828a-7513-d8afb73fd7f0@secure.kjonigsen.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=4016fe8f54874ac785a26897bb766213 Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6352"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Cyrus-JMAP/3.9.0-alpha0-107-g82c3c54364-fm-20230131.002-g82c3c543 Cc: 61302@debbugs.gnu.org To: "Randy Taylor" , "Eli Zaretskii" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Feb 05 22:54: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 1pOmxy-0001T5-HX for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 05 Feb 2023 22:54:30 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pOmxf-0007lW-08; Sun, 05 Feb 2023 16:54:11 -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 1pOmxc-0007lI-AK for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2023 16:54:08 -0500 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 1pOmxW-0000WC-J3 for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2023 16:54:07 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pOmxW-0001A8-98 for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2023 16:54:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Jostein =?UTF-8?Q?Kj=C3=B8nigsen?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 05 Feb 2023 21:54:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61302 X-GNU-PR-Package: emacs X-Debbugs-Original-Cc: "bug-gnu-emacs@gnu.org" Original-Received: via spool by submit@debbugs.gnu.org id=B.16756339954407 (code B ref -1); Sun, 05 Feb 2023 21:54:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 5 Feb 2023 21:53:15 +0000 Original-Received: from localhost ([127.0.0.1]:46624 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pOmwk-000191-Jt for submit@debbugs.gnu.org; Sun, 05 Feb 2023 16:53:14 -0500 Original-Received: from lists.gnu.org ([209.51.188.17]:49402) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pOmwi-00018t-UN for submit@debbugs.gnu.org; Sun, 05 Feb 2023 16:53:13 -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 1pOmwi-0007hO-Nc for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2023 16:53:12 -0500 Original-Received: from mail-qv1-xf29.google.com ([2607:f8b0:4864:20::f29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pOmwg-0000Pi-B9 for bug-gnu-emacs@gnu.org; Sun, 05 Feb 2023 16:53:12 -0500 Original-Received: by mail-qv1-xf29.google.com with SMTP id i1so2439259qvo.9 for ; Sun, 05 Feb 2023 13:53:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kjonigsen.net; s=google; h=subject:cc:to:from:date:references:in-reply-to:message-id :mime-version:user-agent:feedback-id:from:to:cc:subject:date :message-id:reply-to; bh=hMZB5bU/01iLLdRVeIFYaH1Ygs9Vj8lVU+rWvZ2GJIs=; b=EyBy4Cv97eAuNFngbbzCs+72IA3cF2BWVLgR25xq6Bura9QsxcYCVT0BjMG/RDm7te 2G5nGW90KYahPPph6AwKdsn17j4w+0WEyyZvHULtDMUPDF8bf6nNma/atQw/fvl9PWnN qDGr7bDZfMsjtVAWngvotXqVCH12yqrZbLi1M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=subject:cc:to:from:date:references:in-reply-to:message-id :mime-version:user-agent:feedback-id:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hMZB5bU/01iLLdRVeIFYaH1Ygs9Vj8lVU+rWvZ2GJIs=; b=jBJyYF2y7JV9w8UrO2gmWx+BBdECh5hSxe5ckNgPVansofrdB+CJfEvjMhj+202O4z VqJnmixpiFnyJqg1k/wrCxxw6wBgdMZLS4LHcQNopQXYt7ztOtDZtJ7SzIrA2ciHmAyP gvTowx9sibd7vrPPrTVxRu641V4ZJuUiOT/yPQvOfsyzgP1UczQXkTejcbyo64YPX+OA NuUHFzNbjuMGi73jQ5MiKZ4R0xJ7qjABJ26xCZgIdT57fm26xhCxCdRN1rfpzz6c0l+h r6FHscPVXWhnyoSH08LkcBfzogVPdXONerU3bLjg+eIUhT/ooFonvIoSy/6WB1aQDgF9 v+mg== X-Gm-Message-State: AO0yUKV64lsMWouPNDSqUHQQHKb8UY43mgUAc7TfTVPK3qSH59tAJyn6 FvV03ehJx5xWW79Vikj3p7IGIDVABJeeesnS X-Google-Smtp-Source: AK7set8pmFvzZpxvMLNK/ZHdWGW1V4beiK4F43TQXI0WBue8supLj9Y2ywGwQMEWuzdurOEyqRCBUw== X-Received: by 2002:ad4:5caa:0:b0:56b:f0d8:d4cc with SMTP id q10-20020ad45caa000000b0056bf0d8d4ccmr6982771qvh.41.1675633988528; Sun, 05 Feb 2023 13:53:08 -0800 (PST) Original-Received: from auth2-smtp.messagingengine.com (auth2-smtp.messagingengine.com. [66.111.4.228]) by smtp.gmail.com with ESMTPSA id d2-20020a05620a204200b0071f0d0aaef7sm6145057qka.80.2023.02.05.13.53.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Feb 2023 13:53:07 -0800 (PST) Original-Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailauth.nyi.internal (Postfix) with ESMTP id 3F4C027C0054; Sun, 5 Feb 2023 16:53:07 -0500 (EST) Original-Received: from imap50 ([10.202.2.100]) by compute3.internal (MEProxy); Sun, 05 Feb 2023 16:53:07 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrudeggedgudehgecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefofgggkfgjfhffhffvvefutgesrgdtreerreerjeenucfhrhhomheplfho shhtvghinhcumfhjpphnihhgshgvnhcuoehjohhsthgvihhnsehkjhhonhhighhsvghnrd hnvghtqeenucggtffrrghtthgvrhhnpedtvdfhjeekheehffeijeeuvdfguedugeegheek jeeliefggfeitdetvdekveejgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmh epmhgrihhlfhhrohhmpehjohhsthgvihhnodhmvghsmhhtphgruhhthhhpvghrshhonhgr lhhithihqdduvdegkedvtdduudejqdduudegudeffeeftddqjhhoshhtvghinheppehkjh honhhighhsvghnrdhnvghtsehfrghsthhmrghilhdrfhhm X-ME-Proxy: Feedback-ID: iaf4c46de:Fastmail Original-Received: by mailuser.nyi.internal (Postfix, from userid 501) id 15D571700090; Sun, 5 Feb 2023 16:53:07 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface In-Reply-To: Received-SPF: none client-ip=2607:f8b0:4864:20::f29; envelope-from=jostein@kjonigsen.net; helo=mail-qv1-xf29.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action 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:254898 Archived-At: --4016fe8f54874ac785a26897bb766213 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable On Sun, Feb 5, 2023, at 22:30, Randy Taylor wrote: >=20 > That's expected (at least to me) because it's a property. The same app= lies to c-ts-mode and go-ts-mode as well. >=20 I mean=E2=80=A6 yea it=E2=80=99s a property, but it=E2=80=99s clearly a = function-valued property, and you=E2=80=99re calling it.=20 Even simpler: If you store a function reference in a plain variable and = call that variable, is that a variable or a function you=E2=80=99re call= ing? ;) As for consistency, csharp-ts-mode, js-ts-mode, typescript-ts-mode (and = tsx-ts-mode) all does the exact opposite: functions always takes preced= ence over properties. In fact, they mostly highlight declarations of properties only, not regu= lar access, which kind avoids the duality-problem we=E2=80=99re seeing i= n rust-ts-mode in this particular case.=20 Would it be an option/goal to try to align these other modes with a such= a model which is somewhat more clearly defined to make it simpler to r= esolve cases like this? =E2=80=94 Jostein --4016fe8f54874ac785a26897bb766213 Content-Type: text/html;charset=utf-8 Content-Transfer-Encoding: quoted-printable

= On Sun, Feb 5, 2023, at 22:30, Randy Taylor wrote:

That's expected (at least to me) because it's a property. The same appl= ies to c-ts-mode and go-ts-mode as well.

I mean=E2=80=A6 yea it=E2=80=99s a property, but it=E2=80=99= s clearly a function-valued property, and you=E2=80=99re calling it.&nbs= p;

Even simpler: If you store a function re= ference in a plain variable and call that variable, is that a variable o= r a function you=E2=80=99re calling? ;)

As = for consistency, csharp-ts-mode, js-ts-mode, typescript-ts-mode (and tsx= -ts-mode) all does the  exact opposite: functions always takes prec= edence over properties.

In fact, they mostl= y highlight declarations of properties only, not regular access, which k= ind avoids the duality-problem we=E2=80=99re seeing in rust-ts-mode in t= his particular case. 

Would it be an o= ption/goal to try to align these other modes with a such a model which i= s somewhat more clearly defined to make it simpler  to resolve case= s like this?

=E2=80=94
Jostei= n

--4016fe8f54874ac785a26897bb766213--