On 9/24/26 5:06 PM, Arsen Arsenović wrote:
Joseph Myers <[email protected]> writes:

I think the compatible_with name is rather unintuitive.  "compatible" is a
symmetric relation in C, and two types can only be compatible if they have
the same qualifiers, but compatible_with seems to be used here for some
kind of subset relation that might better be named superset_of or
pointer_can_convert_from or similar; nothing about the compatible_with
name serves to tell the reader which way round the subset relation is
meant to be.

Yes, thus my original name was "can_qualify": QS1.can_qualify (QS2).

It is not strictly a superset relation (e.g. {_Atomic} and {} are not
compatible and neither can qualify the other), so I do not think the
superset name is good.

I think "pointer_can_convert_from" is probably too long.

That said, I'm not particularly attached to any name.

I thought 'can_qualify' fits because it should be obvious that one is
operating on qualifier sets, and I've not had any better ideas since.

Suggestions welcome, I'll make the change when we decide.

I think I'd go with superset_of even though it's not quite accurate; the subtleties can be clarified in the function comment, the name can be an approximation.

Jason

Reply via email to