MitalAshok wrote:

Clang only uses `Sema::isLayoutCompatible` in two places: to implement 
`__is_layout_compatible` and [Clang type safety checking 
attributes](https://clang.llvm.org/docs/AttributeReference.html#type-safety-checking),
 which warn if a pointer does not point to a layout compatible type. This only 
affects compiler warnings.

The type safety attributes were introduced by 
e4a5a90e8d6bc6a5ed0bf5f152a658c680b94867 and they were exposed as 
`__is_layout_compatible` by d5922cf72cc18a7ac9f7afd1941ee2f7773d8469 this 
February, so I don't think it was available in Clang 18

https://github.com/llvm/llvm-project/pull/92103
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to