File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
packages/cli/src/languagePlugins/csharp/namespaceResolver Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,8 @@ export interface ExportedSymbol {
3030
3131export interface Namespace {
3232 name : string ;
33+ node : Parser . SyntaxNode ;
34+ identifierNode ?: Parser . SyntaxNode ; // Optional because the root namespace doesn't have an identifier
3335 exports : ExportedSymbol [ ] ;
3436 childrenNamespaces : Namespace [ ] ;
3537}
@@ -56,6 +58,8 @@ export class NamespaceResolver {
5658 const namespaces = [
5759 {
5860 name : "" ,
61+ node : file . rootNode ,
62+ identifierNode : undefined ,
5963 exports : this . #getExportsFromNode( file . rootNode ) ,
6064 childrenNamespaces : this . #getNamespacesFromNode( file . rootNode ) ,
6165 } ,
@@ -71,6 +75,8 @@ export class NamespaceResolver {
7175 . filter ( ( child ) => child . type === "namespace_declaration" )
7276 . map ( ( child ) => ( {
7377 name : this . #getIdentifierNode( child ) . text ,
78+ node : child ,
79+ identifierNode : this . #getIdentifierNode( child ) ,
7480 exports : this . #getExportsFromNode( this . #getDeclarationList( child ) ) ,
7581 childrenNamespaces : this . #getNamespacesFromNode(
7682 this . #getDeclarationList( child ) ,
You can’t perform that action at this time.
0 commit comments