[clang] [Sema] Add check for bitfield assignments to larger integral types (PR #68276)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Oct 6 08:12:00 PDT 2023
================
@@ -0,0 +1,36 @@
+// RUN: %clang_cc1 -Wconversion -fsyntax-only -verify %s
+
+typedef struct _xx {
+ int bf:9; // expected-note{{widen this field to 32 bits to store all values of 'int'}}
+ // expected-note at -1{{widen this field to 16 bits to store all values of 'short'}}
----------------
vabridgers wrote:
Thanks @erichkeane, I'll iterate on improving the note.
https://github.com/llvm/llvm-project/pull/68276
More information about the cfe-commits
mailing list