Migrate deprecated DebugLoc::get to DILocation::get
This migrates all LLVM (except Kaleidoscope and CodeGen/StackProtector.cpp) DebugLoc::get to DILocation::get. The CodeGen/StackProtector.cpp usage may have a nullptr Scope and can trigger an assertion failure, so I don't migrate it. Reviewed By: #debug-info, dblaikie Differential Revision: https://reviews.llvm.org/D93087
This commit is contained in:
@@ -1443,8 +1443,8 @@ static DebugLoc inlineDebugLoc(DebugLoc OrigDL, DILocation *InlinedAt,
|
||||
LLVMContext &Ctx,
|
||||
DenseMap<const MDNode *, MDNode *> &IANodes) {
|
||||
auto IA = DebugLoc::appendInlinedAt(OrigDL, InlinedAt, Ctx, IANodes);
|
||||
return DebugLoc::get(OrigDL.getLine(), OrigDL.getCol(), OrigDL.getScope(),
|
||||
IA);
|
||||
return DILocation::get(Ctx, OrigDL.getLine(), OrigDL.getCol(),
|
||||
OrigDL.getScope(), IA);
|
||||
}
|
||||
|
||||
/// Update inlined instructions' line numbers to
|
||||
|
||||
Reference in New Issue
Block a user