Parse match_first blocks (#7478)

`match_first` is a declaration followed by a curly-brace block of
declarations.

The check phase will ensure only impl decls (or defns) are inside the
block.
This commit is contained in:
Dana Jansens authored and GitHub committed 2026-07-09 15:34:52 +00:00
1 parent bb0d74ba39
commit 11901b1a59
10 files changed
+267

No files matched your search

@@ -129,6 +129,8 @@ static constexpr auto DeclIntroducers = [] {
StateKind::ImplAfterIntroducer);
set(Lex::TokenKind::Interface, NodeKind::InterfaceIntroducer,
StateKind::TypeAfterIntroducerAsInterface);
set(Lex::TokenKind::MatchFirst, NodeKind::MatchFirstIntroducer,
StateKind::MatchFirst);
set(Lex::TokenKind::Namespace, NodeKind::NamespaceStart,
StateKind::Namespace);
set(Lex::TokenKind::Observe, NodeKind::ObserveIntroducer,