mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-09 03:52:19 +02:00
SetCurrentDebugLocation debug check
This commit is contained in:
parent
7f480846ed
commit
9e61cdf75d
1 changed files with 14 additions and 0 deletions
|
@ -4764,6 +4764,20 @@ void BfIRCodeGen::HandleNextCmd()
|
||||||
column = 0;
|
column = 0;
|
||||||
mCurLine = line;
|
mCurLine = line;
|
||||||
mDebugLoc = llvm::DILocation::get(*mLLVMContext, line, column, diScope, diInlinedAt);
|
mDebugLoc = llvm::DILocation::get(*mLLVMContext, line, column, diScope, diInlinedAt);
|
||||||
|
|
||||||
|
#ifdef _DEBUG
|
||||||
|
llvm::DILocation* DL = mDebugLoc;
|
||||||
|
if (DL != NULL)
|
||||||
|
{
|
||||||
|
llvm::Metadata* Parent = DL->getRawScope();
|
||||||
|
llvm::DILocalScope* Scope = DL->getInlinedAtScope();
|
||||||
|
llvm::DISubprogram* SP = Scope->getSubprogram();
|
||||||
|
if (SP != NULL)
|
||||||
|
{
|
||||||
|
BF_ASSERT(SP->describes(mActiveFunction));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case BfIRCmd_Nop:
|
case BfIRCmd_Nop:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue