On Sun, Nov 3, 2024 at 6:58 PM Juri Linkov <juri@linkov.net> wrote:
> I don't know how important this opening-parenthesis-rule is. Actually I don't
> need it. But I guess there were reasons to add it to the regexp.

So there is no bug here and this report could be closed?

If you don't need opening-parenthesis-rule, it's fine
to customize 'outline-regexp' and 'outline-level'.

Please take a look at the example I have given in my very first post.
There you see that font-lock is handling top-level lisp code incorrectly.
This is definitely a bug.

I don't agree with  you that customizing a variable is the recommended
way to fix a bug. But if there's really no other way to handle it, then it
should be documented at least.

Andreas