Subject: Re: bug#78989: 31.0.50; classes and methods inheritance (defclass) seq-contains-p

From: Stefan Monnier <[email-masked]>
Date: Mon, 14 Jul 2025 12:56:11 -0400

> - First if I read carefully none of you told me why my code works with
> the previous version but not with the current.

Yeah, sorry for that.  The reason is quite simple: the code was
significantly massaged/rewritten so as to make it more generic, mostly
for the purpose of sharing that code with that dealing with the
hierarchy of major modes.

> Anyway that is not the question; and I will wait until you will have
> stabilized something to clean my own code.  Stefan you suggest me to
> modify the order of classes in parentship.  But the order was chosen to
> provide certain methods for child classes.

The changes I suggested fix inconsistencies between classes, e.g. you
have a class with parents

    (widobj title)

but `widobj` is a parent of `title` so methods for `widobj` cannot take
precedence of methods for `title`.

> In the code I sent you have not the whole features.

Now you tell me!  🙂

> Please tell me when you will be almost sure that you have put the emacs
> code in a rather stable sate so that I can make my own code fit emacs
> code requiremens.

I just pushed the code to `master`.
It the same as the last patch I sent.
It passes your test without changes to your code but complains
along the way about problems your code needs to fix.
Let us know how it affects your real code.

> Once more I know that this part of Emacs code is also work in progress
> and that such problems may still occur.

Well, not really, it's more a "dark corner" that has not been
heavily exercised.

It would be good to improve the patch I installed by adding
a compile-time warning since it's a better moment to fix the problem
than when running the code.

        Stefan