1
Fork 0

Don't check for recursion in generator witness fields

This commit is contained in:
Michael Goulet 2023-11-08 06:56:06 +00:00
parent dfb9f5df2c
commit 82a2215481
19 changed files with 102 additions and 124 deletions

View file

@ -1361,6 +1361,12 @@ impl CoroutineKind {
}
}
impl CoroutineKind {
pub fn is_fn_like(self) -> bool {
matches!(self, CoroutineKind::Desugared(_, CoroutineSource::Fn))
}
}
impl fmt::Display for CoroutineKind {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
match self {