mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[semantic-sil] Add a semantic attribute "verify.ownership.sil.never".
This semantic attribute allows a user to disable ownership verification on specific functions. The intention is that once I turn on the sil ownership verifier for parts of the stdlib, if an engineer exposes an ownership issue, they can disable ownership verification on that specific function, file a bug, and continue with their work. rdar://31880847
This commit is contained in:
@@ -464,3 +464,7 @@ SubstitutionList SILFunction::getForwardingSubstitutions() {
|
||||
ForwardingSubs = env->getForwardingSubstitutions();
|
||||
return *ForwardingSubs;
|
||||
}
|
||||
|
||||
bool SILFunction::shouldVerifyOwnership() const {
|
||||
return !hasSemanticsAttr("verify.ownership.sil.never");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user