emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Empty headline titles unsupported: Bug?


From: Ihor Radchenko
Subject: Re: Empty headline titles unsupported: Bug?
Date: Sun, 23 May 2021 22:33:19 +0800

Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:

> Because, as I wrote, this is ambiguous. You cannot distinguish the
> following two cases:
>
>   * :mytag:
>   * :myheadline:

Makes sense.

> So, your patch would only move the problem elsewhere. 

Actually, my patch would solve the existing inconsistency.
Org mode already puts tag fontification on :tag: in "* :tag:" headline;
org-get-tags returns ("tag") on such headline; org-set-tags sets the
:tag: on "*" headline making it look like "* :tag:" (which is even
tested in test-org/set-tags); org-tag-line-re used across the
codebase also parses "* :tag:" as headline containing tags. It is only
the org-element parser that does not recognise the :tag: in empty
headline.

> I suggest to not tag emptiness. `org-set-tags' could raise an error in
> this case.

Of course, we can go the other way around and recognise "* :myheadline:"
as non-empty headline with no tags. Though it will be more tricky than
simply changing `org-set-tags' as you suggest.

Best,
Ihor



reply via email to

[Prev in Thread] Current Thread [Next in Thread]