diff options
author | David Blaikie <dblaikie@gmail.com> | 2013-01-05 21:39:33 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2013-01-05 21:39:33 +0000 |
commit | e302b6cb69e96b948101e1ab6c0476187c92ee84 (patch) | |
tree | 4ac4a0f132cabb70692f726022c6ed26f4503f8b /lib | |
parent | 8b2bcf4f753be8100fc712d6267f38b21085fc13 (diff) |
Include access modifiers in subprogram metadata IR comment.
Based on code review feedback in r171604 from Chandler Carruth &
Eric Christopher.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171636 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/IR/DebugInfo.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/IR/DebugInfo.cpp b/lib/IR/DebugInfo.cpp index bec941afda..5dd9dd1c9d 100644 --- a/lib/IR/DebugInfo.cpp +++ b/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 << ']'; |