[PATCH] D56393: [DebugInfo] Don't emit DW_AT_enum_class unless it's actually an 'enum class'.
Paul Robinson via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 8 08:32:28 PST 2019
This revision was not accepted when it landed; it landed in state "Needs Review".
This revision was automatically updated to reflect the committed changes.
Closed by commit rC350636: Don't emit DW_AT_enum_class unless it's actually an 'enum class'. (authored by probinson, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D56393?vs=180501&id=180678#toc
Repository:
rC Clang
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D56393/new/
https://reviews.llvm.org/D56393
Files:
lib/CodeGen/CGDebugInfo.cpp
test/CodeGenCXX/debug-info-enum-class.cpp
Index: test/CodeGenCXX/debug-info-enum-class.cpp
===================================================================
--- test/CodeGenCXX/debug-info-enum-class.cpp
+++ test/CodeGenCXX/debug-info-enum-class.cpp
@@ -52,6 +52,7 @@
// FIXME: this should just be a declaration under -fno-standalone-debug
// CHECK: !DICompositeType(tag: DW_TAG_enumeration_type, name: "E"
// CHECK-SAME: scope: [[TEST2:![0-9]+]]
+// CHECK-NOT: DIFlagFixedEnum
// CHECK-SAME: elements: [[TEST_ENUMS:![0-9]+]]
// CHECK-SAME: identifier: "_ZTSN5test21EE"
// CHECK: [[TEST2]] = !DINamespace(name: "test2"
@@ -67,6 +68,7 @@
// FIXME: this should just be a declaration under -fno-standalone-debug
// CHECK: !DICompositeType(tag: DW_TAG_enumeration_type, name: "E"
// CHECK-SAME: scope: [[TEST3:![0-9]+]]
+// CHECK-NOT: DIFlagFixedEnum
// CHECK-SAME: elements: [[TEST_ENUMS]]
// CHECK-SAME: identifier: "_ZTSN5test31EE"
// CHECK: [[TEST3]] = !DINamespace(name: "test3"
@@ -78,6 +80,7 @@
namespace test4 {
// CHECK: !DICompositeType(tag: DW_TAG_enumeration_type, name: "E"
// CHECK-SAME: scope: [[TEST4:![0-9]+]]
+// CHECK-NOT: DIFlagFixedEnum
// CHECK-SAME: elements: [[TEST_ENUMS]]
// CHECK-SAME: identifier: "_ZTSN5test41EE"
// CHECK: [[TEST4]] = !DINamespace(name: "test4"
Index: lib/CodeGen/CGDebugInfo.cpp
===================================================================
--- lib/CodeGen/CGDebugInfo.cpp
+++ lib/CodeGen/CGDebugInfo.cpp
@@ -2711,7 +2711,7 @@
llvm::DIType *ClassTy = getOrCreateType(ED->getIntegerType(), DefUnit);
return DBuilder.createEnumerationType(EnumContext, ED->getName(), DefUnit,
Line, Size, Align, EltArray, ClassTy,
- Identifier, ED->isFixed());
+ Identifier, ED->isScoped());
}
llvm::DIMacro *CGDebugInfo::CreateMacro(llvm::DIMacroFile *Parent,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56393.180678.patch
Type: text/x-patch
Size: 2044 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190108/56e3d2ce/attachment-0001.bin>
More information about the cfe-commits
mailing list