mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[SILGen] Allocs for VDs are var_decl.
Annotate alloc_stack instructions that correspond to VarDecls with the var_decl flag.
This commit is contained in:
@@ -863,6 +863,7 @@ private:
|
||||
|
||||
if (auto *allocStack = dyn_cast<AllocStackInst>(argrv.getValue())) {
|
||||
allocStack->setArgNo(ArgNo);
|
||||
allocStack->setIsFromVarDecl();
|
||||
if (SGF.getASTContext().SILOpts.supportsLexicalLifetimes(
|
||||
SGF.getModule()) &&
|
||||
SGF.F.getLifetime(pd, allocStack->getType()).isLexical())
|
||||
|
||||
Reference in New Issue
Block a user