From: Rudolf Schlatte <rudi@constantly.at>
To: emacs-devel@gnu.org
Subject: Re: toml-ts-mode: first draft
Date: Tue, 13 Dec 2022 11:45:42 +0100 [thread overview]
Message-ID: <m28rjbk2eh.fsf@eduroam-193-157-204-89.wlan.uio.no> (raw)
In-Reply-To: 7825A406-3F21-4E38-9E9B-B429B9E81B4E@gmail.com
Yuan Fu <casouri@gmail.com> writes:
>
> + (unless (treesit-ready-p 'toml)
> + (error "Tree-sitter for TOML isn't avilable”))
>
> Treesit-ready-p already raises a warning when something goes wrong. So
> you want to either pass the QUIET argument or let it do the barking
> ;-)
I'd expect predicates (functions ending -p) to return T or NIL only and
not have side effects. A function with the described behavior (check
for availability and raise an error if not) could be named something
like `tree-sitter-ensure-language'.
Please ignore this mail if necessary; this small stylistic thing has
been sitting with me for days now and I needed to get it off my chest :-)
Rudi
next prev parent reply other threads:[~2022-12-13 10:45 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-11 13:28 toml-ts-mode: first draft Jostein Kjønigsen
2022-12-11 17:09 ` Juri Linkov
2022-12-11 17:23 ` Jostein Kjønigsen
2022-12-11 17:40 ` Eli Zaretskii
2022-12-11 18:19 ` Stefan Kangas
2022-12-11 18:23 ` Eli Zaretskii
2022-12-11 21:43 ` Stefan Kangas
2022-12-12 3:28 ` Eli Zaretskii
2022-12-12 17:04 ` Juri Linkov
2022-12-11 19:56 ` Jostein Kjønigsen
2022-12-11 20:07 ` Eli Zaretskii
2022-12-11 20:31 ` Jostein Kjønigsen
2022-12-11 20:38 ` Eli Zaretskii
2022-12-11 20:49 ` Jostein Kjønigsen
2022-12-11 23:01 ` Yuan Fu
2022-12-12 13:10 ` Jostein Kjønigsen
2022-12-12 13:53 ` Theodor Thornhill
2022-12-12 20:41 ` Jostein Kjønigsen
2022-12-12 21:17 ` Randy Taylor
2022-12-13 20:43 ` Jostein Kjønigsen
2022-12-13 22:37 ` Randy Taylor
2022-12-14 8:40 ` Jostein Kjønigsen
2022-12-14 13:24 ` Randy Taylor
2022-12-14 18:53 ` toml-ts-mode (code-review done) Jostein Kjønigsen
2022-12-14 19:02 ` Theodor Thornhill
2022-12-14 20:37 ` Yuan Fu
2022-12-14 22:02 ` Jostein Kjønigsen
2022-12-15 2:24 ` Randy Taylor
2022-12-15 12:52 ` Jostein Kjønigsen
2022-12-15 13:22 ` Theodor Thornhill
2022-12-15 13:45 ` Jostein Kjønigsen
2022-12-15 14:22 ` Eli Zaretskii
2022-12-15 14:28 ` Jostein Kjønigsen
2022-12-13 10:45 ` Rudolf Schlatte [this message]
2022-12-13 13:20 ` toml-ts-mode: first draft Eli Zaretskii
2022-12-13 14:22 ` Rudi Schlatte
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m28rjbk2eh.fsf@eduroam-193-157-204-89.wlan.uio.no \
--to=rudi@constantly.at \
--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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).