all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Arash Esbati <arash@gnu.org>
To: emacs-devel@gnu.org
Cc: Christophe Troestler <Christophe.Troestler@umons.ac.be>,
	Dmitry Gutov <dmitry@gutov.dev>
Subject: Re: emacs-29 fbaf113bf38: rust-ts-mode: appropriately fontify doc strings
Date: Mon, 04 Dec 2023 14:27:59 +0100	[thread overview]
Message-ID: <m2bkb6ayhs.fsf@macmutant.fritz.box> (raw)
In-Reply-To: <20231201235520.4AE7EC40272@vcs2.savannah.gnu.org> (Dmitry Gutov's message of "Fri, 1 Dec 2023 18:55:20 -0500 (EST)")

Dmitry Gutov <dgutov@yandex.ru> writes:

> branch: emacs-29
> commit fbaf113bf38ee7db8416f0c0581d479c40b2d69c
> Author: Christophe Troestler <Christophe.Troestler@umons.ac.be>
> Commit: Dmitry Gutov <dmitry@gutov.dev>
>
>     rust-ts-mode: appropriately fontify doc strings
>     
>     * lisp/progmodes/rust-ts-mode.el
>     (rust-ts-mode--comment-docstring): New function.
>     (rust-ts-mode--font-lock-settings): Use it
>     (https://lists.gnu.org/archive/html/emacs-devel/2023-12/msg00019.html).
> [...]
> +(defun rust-ts-mode--comment-docstring (node override start end &rest _args)
> +  "Use the comment or documentation face appropriately for comments."
> +  (let* ((beg (treesit-node-start node))
> +         (end (treesit-node-end node))
> +         (face (save-excursion
> +                 (goto-char beg)
> +                 (if (looking-at "///")
> +                     'font-lock-doc-face
> +                   'font-lock-comment-face))))
> +    (treesit-fontify-with-override beg end face override start end)))
> +

I think this change now produces:

  In rust-ts-mode--comment-docstring:
  progmodes/rust-ts-mode.el:296:61: Warning: Unused lexical argument ‘end’

This is with Emacs from master (cf11fdfd8e) on macOS.

Best, Arash



       reply	other threads:[~2023-12-04 13:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <170147491995.22987.13141633400020290013@vcs2.savannah.gnu.org>
     [not found] ` <20231201235520.4AE7EC40272@vcs2.savannah.gnu.org>
2023-12-04 13:27   ` Arash Esbati [this message]
2023-12-04 13:42     ` emacs-29 fbaf113bf38: rust-ts-mode: appropriately fontify doc strings Dmitry Gutov
2023-12-04 15:04       ` Arash Esbati

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2bkb6ayhs.fsf@macmutant.fritz.box \
    --to=arash@gnu.org \
    --cc=Christophe.Troestler@umons.ac.be \
    --cc=dmitry@gutov.dev \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.