Skip to content

Commit cdb2154

Browse files
authored
Merge pull request #16854 from dcci/followups
2 parents 07d4303 + cbac4b1 commit cdb2154

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

include/swift/SIL/SILLocation.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ class SILLocation {
428428
static DebugLoc decode(SourceLoc Loc, const SourceManager &SM);
429429

430430
/// Return the decoded debug location.
431-
DebugLoc decodeDebugLoc(const SourceManager &SM) const {
431+
LLVM_NODISCARD DebugLoc decodeDebugLoc(const SourceManager &SM) const {
432432
return isDebugInfoLoc() ? Loc.DebugInfoLoc
433433
: decode(getDebugSourceLoc(), SM);
434434
}

lib/IRGen/IRGenSIL.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -737,6 +737,8 @@ class IRGenSILFunction :
737737
return;
738738

739739
llvm::IRBuilder<> ZeroInitBuilder(AI->getNextNode());
740+
741+
// No debug location is how LLVM marks prologue instructions.
740742
ZeroInitBuilder.SetCurrentDebugLocation(nullptr);
741743
auto *BC =
742744
ZeroInitBuilder.CreateBitCast(AI, IGM.OpaquePtrTy->getPointerTo());

0 commit comments

Comments
 (0)