GNU bug report logs -
#61302
29.0.60; rust-ts-mode does not show function-invocation on field-properties
Previous Next
Reported by: jostein <at> kjonigsen.net
Date: Sun, 5 Feb 2023 20:16:01 UTC
Severity: normal
Found in version 29.0.60
Done: Dmitry Gutov <dgutov <at> yandex.ru>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
On 14/02/2023 14:39, Randy Taylor wrote:
> On Tuesday, February 14th, 2023 at 06:42, Jostein Kjønigsen
> <jostein <at> secure.kjonigsen.net> wrote:
>>Haven given the latest patch a try on a less macro-ridden codebase I have to
> say it looks a lot better. In general I would say for this other
> code-base it looks favourable to rust-mode.
>>
>>If there's one thing which still seems to be done better in rust-mode
> (not nitpicking the variable highlighting), it would be fully namespaces
> function calls within classes.
>>
>>Consider the following code:
>>
>>extern crate claxon;
>>let result = claxon::FlacReader::open(path);
>>
>>While rust-ts-mode correctly identifies that open() is a function-call,
> rust-mode correctly identified FlacReader as a class.
>
> Thanks for testing. I've attached a patch fixing this.
>
> I had deleted a query I thought was now covered :). I look forward to
> the day we have highlight tests!
Thank you, looks almost perfect (see below), I've pushed that to emacs-29.
Highlighting tests are a pain to write, but the initiative is always
welcome. ;-) In the meantime, at least tree-sitter validates the
queries, which lowers the odds of typos in font-lock rules.
Speaking of a problem, the solution with applying the explicit 'default'
face doesn't seem ideal. Aside from the redundancy in the resulting
buffer structure (with very little practical downside), it also makes
the 'vc-diff' buffers look like this on the attached screenshots (the
'default' face's background overrides the greens and reds).
I couldn't find a quick solution to this problem, so I pushed the
existing code for now.
[Screenshot from 2023-02-14 23-42-25.png (image/png, attachment)]
[Screenshot from 2023-02-14 23-42-40.png (image/png, attachment)]
This bug report was last modified 2 years and 91 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.