philnik777 wrote: @cor3ntin @erichkeane How would you feel about a conceptually more general attribute, but remove any stability commitments?
Specifically, I had in mind that we could rename this something like `[[__clang_experimental__::__container_of_type__(T)]]` (I'd probably just hard-code the underscores, since this wouldn't be intended for general use) and the only guarantee that is being made is that `__has_cpp_attribute(__clang_experimental__::__container_of_type__)` changes the value if the implementation changes in any (possibly incompatible with previous versions) way. That would allow for modifications or removal at any point, which should remove any maintainability concerns. On the libc++ side we'd of course then check for `__has_cpp_attribute(__clang_experimental__::__container_of_type__) == 1`. https://github.com/llvm/llvm-project/pull/211231 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
