mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Rename Name -> IdentifierName given that we have several other kinds of parse nodes that represent names. (#3453)
Factor out common checking handling for the different kinds of unqualified names
This commit is contained in:
@@ -20,17 +20,17 @@ interface Foo {
|
||||
// CHECK:STDOUT: parse_tree: [
|
||||
// CHECK:STDOUT: {kind: 'FileStart', text: ''},
|
||||
// CHECK:STDOUT: {kind: 'InterfaceIntroducer', text: 'interface'},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'Foo'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'Foo'},
|
||||
// CHECK:STDOUT: {kind: 'InterfaceDefinitionStart', text: '{', subtree_size: 3},
|
||||
// CHECK:STDOUT: {kind: 'FunctionIntroducer', text: 'fn'},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'Sub'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'Sub'},
|
||||
// CHECK:STDOUT: {kind: 'ImplicitParamListStart', text: '['},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'me'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'me'},
|
||||
// CHECK:STDOUT: {kind: 'InvalidParse', text: 'Self', has_error: yes},
|
||||
// CHECK:STDOUT: {kind: 'BindingPattern', text: 'me', has_error: yes, subtree_size: 3},
|
||||
// CHECK:STDOUT: {kind: 'ImplicitParamList', text: ']', has_error: yes, subtree_size: 5},
|
||||
// CHECK:STDOUT: {kind: 'ParamListStart', text: '('},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'b'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'b'},
|
||||
// CHECK:STDOUT: {kind: 'SelfTypeNameExpr', text: 'Self'},
|
||||
// CHECK:STDOUT: {kind: 'BindingPattern', text: ':', subtree_size: 3},
|
||||
// CHECK:STDOUT: {kind: 'ParamList', text: ')', subtree_size: 5},
|
||||
@@ -38,14 +38,14 @@ interface Foo {
|
||||
// CHECK:STDOUT: {kind: 'ReturnType', text: '->', subtree_size: 2},
|
||||
// CHECK:STDOUT: {kind: 'FunctionDecl', text: ';', subtree_size: 15},
|
||||
// CHECK:STDOUT: {kind: 'FunctionIntroducer', text: 'fn'},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'Mul'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'Mul'},
|
||||
// CHECK:STDOUT: {kind: 'ImplicitParamListStart', text: '['},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'Self', has_error: yes},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'Self', has_error: yes},
|
||||
// CHECK:STDOUT: {kind: 'InvalidParse', text: 'Self', has_error: yes},
|
||||
// CHECK:STDOUT: {kind: 'BindingPattern', text: 'Self', has_error: yes, subtree_size: 3},
|
||||
// CHECK:STDOUT: {kind: 'ImplicitParamList', text: ']', has_error: yes, subtree_size: 5},
|
||||
// CHECK:STDOUT: {kind: 'ParamListStart', text: '('},
|
||||
// CHECK:STDOUT: {kind: 'Name', text: 'b'},
|
||||
// CHECK:STDOUT: {kind: 'IdentifierName', text: 'b'},
|
||||
// CHECK:STDOUT: {kind: 'SelfTypeNameExpr', text: 'Self'},
|
||||
// CHECK:STDOUT: {kind: 'BindingPattern', text: ':', subtree_size: 3},
|
||||
// CHECK:STDOUT: {kind: 'ParamList', text: ')', subtree_size: 5},
|
||||
|
||||
Reference in New Issue
Block a user