1
Fork 0

Create opaque definitions in resolver.

This commit is contained in:
Camille GILLOT 2024-08-24 01:44:52 +00:00
parent 9649706ead
commit f68f66538a
8 changed files with 91 additions and 97 deletions

View file

@ -1485,7 +1485,7 @@ impl<'a> Visitor<'a> for AstValidator<'a> {
let disallowed = (!tilde_const_allowed).then(|| match fk {
FnKind::Fn(_, ident, _, _, _, _) => TildeConstReason::Function { ident: ident.span },
FnKind::Closure(_, _, _) => TildeConstReason::Closure,
FnKind::Closure(..) => TildeConstReason::Closure,
});
self.with_tilde_const(disallowed, |this| visit::walk_fn(this, fk));
}