diff options
author | Devang Patel <dpatel@apple.com> | 2010-01-14 18:06:13 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2010-01-14 18:06:13 +0000 |
commit | 98a200bfe19f4cf255bd3ca0220e2f68e616ee2c (patch) | |
tree | 94616476f3b723754bf71b1e51e147311467b407 /lib/CodeGen/CGDebugInfo.cpp | |
parent | 9edad9b6184c730a73dc9241c043ea3bae54189f (diff) |
Add comment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93434 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDebugInfo.cpp')
-rw-r--r-- | lib/CodeGen/CGDebugInfo.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/CodeGen/CGDebugInfo.cpp b/lib/CodeGen/CGDebugInfo.cpp index bad5fbb980..6cfe503d3c 100644 --- a/lib/CodeGen/CGDebugInfo.cpp +++ b/lib/CodeGen/CGDebugInfo.cpp @@ -1014,6 +1014,9 @@ void CGDebugInfo::EmitFunctionStart(GlobalDecl GD, QualType FnType, LinkageName = Name; } + // It is expected that CurLoc is set before using EmitFunctionStart. + // Usually, CurLoc points to the left bracket location of compound + // statement representing function body. llvm::DICompileUnit Unit = getOrCreateCompileUnit(CurLoc); SourceManager &SM = CGM.getContext().getSourceManager(); unsigned LineNo = SM.getPresumedLoc(CurLoc).getLine(); |