We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 47fe49a + 91777ab commit 7542d19Copy full SHA for 7542d19
include/swift/SIL/ApplySite.h
@@ -534,6 +534,18 @@ class FullApplySite : public ApplySite {
534
return getCalleeArgIndex(op) < getNumIndirectSILResults();
535
}
536
537
+ /// Is this an ApplySite that begins the evaluation of a coroutine.
538
+ bool beginsCoroutineEvaluation() const {
539
+ switch (getKind()) {
540
+ case FullApplySiteKind::ApplyInst:
541
+ case FullApplySiteKind::TryApplyInst:
542
+ return false;
543
+ case FullApplySiteKind::BeginApplyInst:
544
+ return true;
545
+ }
546
+ llvm_unreachable("Covered switch isn't covered?!");
547
548
+
549
/// If this is a terminator apply site, then pass the first instruction of
550
/// each successor to fun. Otherwise, pass std::next(Inst).
551
///
0 commit comments