Skip to content

Commit d95ec67

Browse files
committed
[semantic-arc-opts] Fix a thinko.
This can only affect us in code where we use address phi arguments (which can never happen in raw sil where this runs today). I am going to be moving it later once I finish bringing up lowering ownership after diagnostics.
1 parent 90c4891 commit d95ec67

File tree

3 files changed

+438
-2
lines changed

3 files changed

+438
-2
lines changed

lib/SILOptimizer/Mandatory/SemanticARCOpts.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ static bool isWrittenTo(SILFunction &f, SILValue value) {
369369
// conservative and assume that the value is written to.
370370
const auto &storage = findAccessedStorageNonNested(value);
371371
if (!storage)
372-
return false;
372+
return true;
373373

374374
// Then see if we ever write to this address in a flow insensitive
375375
// way (ignoring stores that are obviously the only initializer to

0 commit comments

Comments
 (0)