summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/DebugInfo.cpp
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2013-01-05 21:39:33 +0000
committerDavid Blaikie <dblaikie@gmail.com>2013-01-05 21:39:33 +0000
commite05754576b306abcd25dadce3aab178bb660644a (patch)
tree09b027f6e7f94c8cb786781ed38f63d93f48decf /llvm/lib/IR/DebugInfo.cpp
parent09e0797953efdbc8eebabfd10a45ae56cb33f8bf (diff)
downloadbcm5719-llvm-e05754576b306abcd25dadce3aab178bb660644a.tar.gz
bcm5719-llvm-e05754576b306abcd25dadce3aab178bb660644a.zip
Include access modifiers in subprogram metadata IR comment.
Based on code review feedback in r171604 from Chandler Carruth & Eric Christopher. llvm-svn: 171636
Diffstat (limited to 'llvm/lib/IR/DebugInfo.cpp')
-rw-r--r--llvm/lib/IR/DebugInfo.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/IR/DebugInfo.cpp b/llvm/lib/IR/DebugInfo.cpp
index bec941afda3..5dd9dd1c9d5 100644
--- a/llvm/lib/IR/DebugInfo.cpp
+++ b/llvm/lib/IR/DebugInfo.cpp
@@ -1122,6 +1122,11 @@ void DISubprogram::printInternal(raw_ostream &OS) const {
if (getScopeLineNumber() != getLineNumber())
OS << " [scope " << getScopeLineNumber() << "]";
+ if (isPrivate())
+ OS << " [private]";
+ else if (isProtected())
+ OS << " [protected]";
+
StringRef Res = getName();
if (!Res.empty())
OS << " [" << Res << ']';
OpenPOWER on IntegriCloud