From: john muhl <jm@pub.pink>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 74235@debbugs.gnu.org
Subject: bug#74235: [PATCH] ; Remove 'nil' from some 'lua-ts-mode' options
Date: Thu, 07 Nov 2024 09:04:42 -0600 [thread overview]
Message-ID: <87zfmbozjp.fsf@pub.pink> (raw)
In-Reply-To: <86y11vr3e5.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 07 Nov 2024 07:58:42 +0200")
Eli Zaretskii <eliz@gnu.org> writes:
>> From: john muhl <jm@pub.pink>
>> Date: Wed, 06 Nov 2024 15:22:34 -0600
>>
>> * lisp/progmodes/lua-ts-mode.el (lua-ts-luacheck-program):
>> (lua-ts-inferior-program): Remove 'nil' as it is never a valid
>> choice. (Bug#74235)
>
> IMO, the use of these options in the code is not clean: if these
> programs are not installed, the commands which reference these options
> will signal errors whose diagnostic might not clearly indicate the
> root cause. I would like to see a cleaner handling of such
> contingencies by this mode. Does this make sense, and if so, would
> you like to suggest changes to that effect?
Good point. I’ll work on that very soon.
>> (defcustom lua-ts-luacheck-program "luacheck"
>> "Location of the Luacheck program."
>> - :type '(choice (const :tag "None" nil) string)
>> + :type 'string
>> :version "30.1")
>
> I think if we require this to be the name of a program, 'file' is a
> better value for :type, because it allows completion if the user types
> an absolute file name.
Makes sense.
>> (defcustom lua-ts-inferior-buffer "*Lua*"
>> @@ -83,7 +83,7 @@ lua-ts-inferior-buffer
>>
>> (defcustom lua-ts-inferior-program "lua"
>> "Program to run in the inferior Lua process."
>> - :type '(choice (const :tag "None" nil) string)
>> + :type 'string
>> :version "30.1")
>>
>> (defcustom lua-ts-inferior-options '("-i")
>> --
>> 2.47.0
>>
>> john muhl <jm@pub.pink> writes:
>>
>> > Tags: patch
>> >
>> > For some silly reason the lua-ts-{inferior,luacheck}-program
>> > options ended up with an option for “None”. Obviously setting your
>> > Lua interpreter or linter program to nil is not going to work.
>> >
>> > Any chance it could make it into emacs-30?
>
> lua-ts-mode is new in Emacs 30, so we can install these changes on the
> release branch, as a stopgap. But I'd like to see a cleaner solution
> installed later, even if we decide to install that on master due to
> its complexity.
>
> Thanks.
Then let’s put this one on hold and I’ll work on the improvements
you suggest. Hopefully it doesn’t require significant changes and
we can skip the stopgap and get it all into 30.
Thanks for the help.
next prev parent reply other threads:[~2024-11-07 15:04 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-06 21:19 bug#74235: [PATCH] ; Remove 'nil' from some 'lua-ts-mode' options john muhl
2024-11-06 21:22 ` john muhl
2024-11-07 5:58 ` Eli Zaretskii
2024-11-07 15:04 ` john muhl [this message]
2024-11-08 14:57 ` john muhl
2024-11-08 15:24 ` Eli Zaretskii
2024-11-09 20:54 ` john muhl
2024-11-10 5:43 ` Eli Zaretskii
2024-11-10 14:48 ` john muhl
2024-11-14 8:26 ` Eli Zaretskii
2024-11-10 5:45 ` Philip Kaludercic
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=87zfmbozjp.fsf@pub.pink \
--to=jm@pub.pink \
--cc=74235@debbugs.gnu.org \
--cc=eliz@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).