mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-11-15 00:18:33 +00:00
Parse support for simple friend declarations (#7889)
This change only supports `friend` with an identifier operand, because there are a lot of open questions about the desired syntax beyond that.
This commit is contained in:
1 parent
d31a8b67d3
commit
8f258eaaa6
9 files changed
+208
No files matched your search
@@ -123,6 +123,8 @@ static constexpr auto DeclIntroducers = [] {
|
||||
set(Lex::TokenKind::Export, NodeKind::ExportIntroducer,
|
||||
StateKind::ExportName);
|
||||
// TODO: Treat `extend` as a declaration introducer.
|
||||
set(Lex::TokenKind::Friend, NodeKind::FriendIntroducer,
|
||||
StateKind::FriendDecl);
|
||||
set(Lex::TokenKind::Fn, NodeKind::FunctionIntroducer,
|
||||
StateKind::FunctionIntroducer);
|
||||
set(Lex::TokenKind::Impl, NodeKind::ImplIntroducer,
|
||||
|
||||
Reference in new issue
Block a user