Skip to content

Commit 35737be

Browse files
committed
[clang][NFC] Annotate CodeGenFunction.h with preferred_type
This helps debuggers to display values in bit-fields in a more helpful way.
1 parent fd80304 commit 35737be

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

clang/lib/CodeGen/CodeGenFunction.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,7 @@ template <> struct DominatingValue<RValue> {
203203

204204
llvm::Value *Value;
205205
llvm::Type *ElementType;
206+
LLVM_PREFERRED_TYPE(Kind)
206207
unsigned K : 3;
207208
unsigned Align : 29;
208209
saved_type(llvm::Value *v, llvm::Type *e, Kind k, unsigned a = 0)
@@ -650,9 +651,11 @@ class CodeGenFunction : public CodeGenTypeCache {
650651
struct LifetimeExtendedCleanupHeader {
651652
/// The size of the following cleanup object.
652653
unsigned Size;
653-
/// The kind of cleanup to push: a value from the CleanupKind enumeration.
654+
/// The kind of cleanup to push.
655+
LLVM_PREFERRED_TYPE(CleanupKind)
654656
unsigned Kind : 31;
655657
/// Whether this is a conditional cleanup.
658+
LLVM_PREFERRED_TYPE(bool)
656659
unsigned IsConditional : 1;
657660

658661
size_t getSize() const { return Size; }

0 commit comments

Comments
 (0)