mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Merge pull request #71803 from jckarter/begin-borrow-fixed-switch-subject
SIL: Enclose switch subjects in a new begin_borrow [fixed] variant.
This commit is contained in:
@@ -817,12 +817,13 @@ public:
|
||||
BeginBorrowInst *createBeginBorrow(SILLocation Loc, SILValue LV,
|
||||
bool isLexical = false,
|
||||
bool hasPointerEscape = false,
|
||||
bool fromVarDecl = false) {
|
||||
bool fromVarDecl = false,
|
||||
bool fixed = false) {
|
||||
assert(getFunction().hasOwnership());
|
||||
assert(!LV->getType().isAddress());
|
||||
return insert(new (getModule())
|
||||
BeginBorrowInst(getSILDebugLocation(Loc), LV, isLexical,
|
||||
hasPointerEscape, fromVarDecl));
|
||||
hasPointerEscape, fromVarDecl, fixed));
|
||||
}
|
||||
|
||||
/// Convenience function for creating a load_borrow on non-trivial values and
|
||||
|
||||
Reference in New Issue
Block a user