Fix a couple more DefKind discrepancies between DefKind::Closure and DefKind::SyntheticCoroutineBody
This commit is contained in:
parent
af1ca7794a
commit
4beb1cf9e5
4 changed files with 44 additions and 3 deletions
|
@ -287,7 +287,10 @@ impl DefKind {
|
|||
|
||||
#[inline]
|
||||
pub fn is_fn_like(self) -> bool {
|
||||
matches!(self, DefKind::Fn | DefKind::AssocFn | DefKind::Closure)
|
||||
matches!(
|
||||
self,
|
||||
DefKind::Fn | DefKind::AssocFn | DefKind::Closure | DefKind::SyntheticCoroutineBody
|
||||
)
|
||||
}
|
||||
|
||||
/// Whether `query get_codegen_attrs` should be used with this definition.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue