llvm-project/clang/lib
Richard Smith b5a317fbf6 Non-zero-length bit-fields make a class non-empty.
This implements the rule intended by the standard (see LWG 2358)
and the rule intended by the Itanium C++ ABI (see
https://github.com/itanium-cxx-abi/cxx-abi/pull/51), and makes
Clang match the behavior of GCC, ICC, and MSVC.

A pedantic reading of both the standard and the ABI indicate that Clang
is currently technically correct, but that's not worth much when it's
clear that the wording is wrong in both those places.

This is an ABI break for classes that derive from a class that is empty
other than one or more unnamed non-zero-length bit-fields. Such cases
are expected to be rare, but -fclang-abi-compat=6 restores the old
behavior just in case.

Differential Revision: https://reviews.llvm.org/D45174

llvm-svn: 331620
2018-05-07 06:43:30 +00:00
..
ARCMigrate PR37189 Fix incorrect end source location and spelling for a split '>>' token. 2018-04-30 05:25:48 +00:00
AST Non-zero-length bit-fields make a class non-empty. 2018-05-07 06:43:30 +00:00
ASTMatchers Fix typos in clang 2018-04-06 15:14:32 +00:00
Analysis Track the result of evaluating a computed noexcept specification on the 2018-05-03 03:58:32 +00:00
Basic [X86] directstore and movdir64b intrinsics 2018-05-01 10:05:42 +00:00
CodeGen [ThinLTO] Support opt remarks options with distributed ThinLTO backends 2018-05-05 14:37:29 +00:00
CrossTU [CrossTU] Fix handling of Cross Translation Unit directory path 2017-10-27 12:53:37 +00:00
Driver [clang-cl] Print /showIncludes to stderr, if used in combination with /E, /EP or /P 2018-05-04 15:58:31 +00:00
Edit PR37189 Fix incorrect end source location and spelling for a split '>>' token. 2018-04-30 05:25:48 +00:00
Format [clang-format] Refactor #include insertion/deletion functionality into a class. 2018-05-04 17:55:13 +00:00
Frontend [ThinLTO] Support opt remarks options with distributed ThinLTO backends 2018-05-05 14:37:29 +00:00
FrontendTool Make a build bot happy. 2018-02-10 14:26:53 +00:00
Headers [X86] Fix some inconsistent formatting in the first line of our intrinsics headers. 2018-05-04 21:45:25 +00:00
Index Implement P0482R2, support for char8_t type. 2018-05-01 05:02:45 +00:00
Lex Implement P0482R2, support for char8_t type. 2018-05-01 05:02:45 +00:00
Parse Track the result of evaluating a computed noexcept specification on the 2018-05-03 03:58:32 +00:00
Rewrite PR37189 Fix incorrect end source location and spelling for a split '>>' token. 2018-04-30 05:25:48 +00:00
Sema Disallow pointers to const in __sync_fetch_and_xxx. 2018-05-05 17:38:42 +00:00
Serialization Track the result of evaluating a computed noexcept specification on the 2018-05-03 03:58:32 +00:00
StaticAnalyzer Fix a couple places that immediately called operator-> on the result of dyn_cast. 2018-05-05 01:58:26 +00:00
Tooling IWYU for llvm-config.h in clang. See r331124 for details. 2018-04-30 13:52:15 +00:00
CMakeLists.txt Add Cross Translation Unit support library 2017-09-22 11:11:01 +00:00