Shuo Shen <shuoshen...@gmail.com> writes:

>> Also, we should probably make this constant internal. I am not sure if
>> this design will stick, so let's introduce the minimal number of new
>> public variables.
>
> How do I define an internal constant? Like org--tag-valid-char-set?

Yes. See D.1 Emacs Lisp Coding Conventions section of Elisp manual.

> Having this as a function instead of a const is OK, but I don't think it's too
> much of a difference tbh. There's rarely a scenario you would need to call 
> this
> function at run time with a different input value. I can update if you
> feel strongly about
> this.

I do not feel strongly.

>> I do not think that we really need this one, considering my other comments.
>
> The alternative is to copy paste (format
> "\\(:\\([%s:]+\\):\\)" org-tag-valid-char-set) 3 times if we don't
> have this as a variable. I understand the need to reduce the number of
> confusing vars, but I feel this one is well deserved because of how
> often it's needed in other places.

Ok.

>> P.S. Please avoid top-posting. See 
>> https://orgmode.org/worg/org-mailing-list.html#orgc4ee9e4
>
> Sounds good. Please let me know if this works.

This message looks good, yes.

> From 2fa32c724fe1c6f6ebe4225fc49cc5a3e05eab30 Mon Sep 17 00:00:00 2001
> From: Shuo Shen <shuoshen...@gmail.com>
> Date: Fri, 9 May 2025 11:06:35 -0700
> Subject: [PATCH] lisp/org.el: refactor the org-tag family regex to prevent
>  duplicates

The patch looks reasonable from a quick glance, but I did not dig
further yet. Please fix "make test" failures first.

-- 
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to