Files
swift-mirror/lib/SILOptimizer/Transforms/SILMem2Reg.cpp
Meghana Gupta c89dcd8019 Fix handling of none value stores to non-trivial enums in Mem2Reg
We allow none values to be stored to a non-trivial enum.
For such store_borrow, `LiveValues::forValues` used
an Owned storage type, but endLexicalLifetime expected Guaranteed
storage type, leading to a compiler crash.

For store_borrow, use the LiveValues::forGuaranteed and for store
use LiveValues::forOwned to avoid this.

Fixes rdar://114390472
2023-09-04 23:31:29 -07:00

88 KiB