mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-08 20:30:50 +00:00
Line number 0 indicates there is no source line/file name info available for this construct.
llvm-svn: 116061
This commit is contained in:
parent
8d4bb23650
commit
3090b0ebf1
@ -507,6 +507,8 @@ void DwarfDebug::addSourceLine(DIE *Die, DIVariable V) {
|
||||
return;
|
||||
|
||||
unsigned Line = V.getLineNumber();
|
||||
if (Line == 0)
|
||||
return;
|
||||
unsigned FileID = GetOrCreateSourceID(V.getContext().getDirectory(),
|
||||
V.getContext().getFilename());
|
||||
assert(FileID && "Invalid file id");
|
||||
@ -522,6 +524,8 @@ void DwarfDebug::addSourceLine(DIE *Die, DIGlobalVariable G) {
|
||||
return;
|
||||
|
||||
unsigned Line = G.getLineNumber();
|
||||
if (Line == 0)
|
||||
return;
|
||||
unsigned FileID = GetOrCreateSourceID(G.getContext().getDirectory(),
|
||||
G.getContext().getFilename());
|
||||
assert(FileID && "Invalid file id");
|
||||
@ -557,7 +561,7 @@ void DwarfDebug::addSourceLine(DIE *Die, DIType Ty) {
|
||||
return;
|
||||
|
||||
unsigned Line = Ty.getLineNumber();
|
||||
if (!Ty.getContext().Verify())
|
||||
if (Line == 0 || !Ty.getContext().Verify())
|
||||
return;
|
||||
unsigned FileID = GetOrCreateSourceID(Ty.getContext().getDirectory(),
|
||||
Ty.getContext().getFilename());
|
||||
@ -574,6 +578,8 @@ void DwarfDebug::addSourceLine(DIE *Die, DINameSpace NS) {
|
||||
return;
|
||||
|
||||
unsigned Line = NS.getLineNumber();
|
||||
if (Line == 0)
|
||||
return;
|
||||
StringRef FN = NS.getFilename();
|
||||
StringRef Dir = NS.getDirectory();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user