Unverified Commit fd2ffc1c authored by Vlad Serebrennikov's avatar Vlad Serebrennikov Committed by GitHub
Browse files

[clang] Reject incomplete types in `__is_layout_compatible()` (#87869)

This is a follow-up to #81506. As discussed in #87737, we're rejecting
incomplete types, save for exceptions listed in the C++ standard (`void`
and arrays of unknown bound). Note that arrays of unknown bound of
incomplete types are accepted.

Since we're happy with the current behavior of this intrinsic for
flexible array members
(https://github.com/llvm/llvm-project/pull/87737#discussion_r1553652570),
I added a couple of tests for that as well.
parent 125c9cf1
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment