[llvm-commits] [llvm-gcc-4.2] r60967 - /llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
Devang Patel
dpatel at apple.com
Fri Dec 12 14:41:51 PST 2008
Author: dpatel
Date: Fri Dec 12 16:41:51 2008
New Revision: 60967
URL: http://llvm.org/viewvc/llvm-project?rev=60967&view=rev
Log:
Encode member's access level.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
Modified: llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp?rev=60967&r1=60966&r2=60967&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp Fri Dec 12 16:41:51 2008
@@ -588,12 +588,18 @@
tree FieldNodeType = FieldType(Member);
DIType MemberType = getOrCreateType(FieldNodeType, Unit);
const char *MemberName = GetNodeName(Member);
-
+ unsigned Flags = 0;
+ if (TREE_PROTECTED(Member))
+ Flags = DW_ACCESS_protected;
+ else if (TREE_PRIVATE(Member))
+ Flags = DW_ACCESS_private;
+ else
+ Flags = DW_ACCESS_public;
DIType DTy =
DebugFactory.CreateDerivedType(DW_TAG_member, Unit, MemberName,
Unit, MemLoc.line, NodeSizeInBits(Member),
NodeAlignInBits(FieldNodeType),
- 0, 0, MemberType);
+ 0, Flags, MemberType);
EltTys.push_back(DTy);
} else {
DEBUGASSERT(0 && "Unsupported member tree code!");
More information about the llvm-commits
mailing list