[PATCH] D21011: [codeview] Add complex record type translation
David Majnemer via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 16 12:37:08 PDT 2016
majnemer added inline comments.
================
Comment at: lib/CodeGen/AsmPrinter/CodeViewDebug.cpp:751-752
@@ -746,1 +750,4 @@
+ return lowerTypeMemberFunction(cast<DISubroutineType>(Ty), ClassTy);
+ else
+ return lowerTypeFunction(cast<DISubroutineType>(Ty));
case dwarf::DW_TAG_class_type:
----------------
else after return is discouraged by the coding standards: http://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return
================
Comment at: lib/CodeGen/AsmPrinter/CodeViewDebug.cpp:1132
@@ +1131,3 @@
+
+struct llvm::ClassInfo {
+ struct MemberInfo {
----------------
Does this need to be in the LLVM namespace? Why not stick it in an anonymous namespace?
================
Comment at: lib/CodeGen/AsmPrinter/CodeViewDebug.cpp:1263
@@ -1066,1 +1262,3 @@
+ TypeIndex FieldTI;
+ TypeIndex VShapeTI; // Dummy
unsigned FieldCount;
----------------
Why not use `std::ignore` instead?
================
Comment at: lib/CodeGen/AsmPrinter/CodeViewDebug.cpp:1283
@@ +1282,3 @@
+
+ // Create members
+ for (ClassInfo::MemberInfo &MemberInfo : Info.Members) {
----------------
Comments should end in a period.
================
Comment at: lib/CodeGen/AsmPrinter/CodeViewDebug.cpp:1299
@@ +1298,3 @@
+
+ //FIXME: Handle bitfield type memeber.
+ OffsetInBytes += Member->getOffsetInBits() / 8;
----------------
Please clang-format this.
http://reviews.llvm.org/D21011
More information about the llvm-commits
mailing list