@@ -894,9 +894,16 @@ export class TreeVisitor extends ParseTreeWalker {
894
894
}
895
895
}
896
896
897
- private getScipSymbol ( node : ParseNode , opts : ScipSymbolOptions | undefined = undefined ) : ScipSymbol {
897
+ private getScipSymbol (
898
+ node : ParseNode ,
899
+ debug : boolean = false ,
900
+ opts : ScipSymbolOptions | undefined = undefined
901
+ ) : ScipSymbol {
898
902
const existing = this . rawGetLsifSymbol ( node ) ;
899
903
if ( existing ) {
904
+ if ( debug ) {
905
+ console . log ( 'got existing' ) ;
906
+ }
900
907
return existing ;
901
908
}
902
909
@@ -922,6 +929,9 @@ export class TreeVisitor extends ParseTreeWalker {
922
929
}
923
930
924
931
moduleName = nodeFileInfo . moduleName ;
932
+ if ( debug ) {
933
+ console . log ( `moduleName = ${ moduleName } ` ) ;
934
+ }
925
935
if ( moduleName == 'builtins' ) {
926
936
return this . emitBuiltinScipSymbol ( node ) ;
927
937
} else if ( Hardcoded . stdlib_module_names . has ( moduleName ) ) {
@@ -1092,11 +1102,14 @@ export class TreeVisitor extends ParseTreeWalker {
1092
1102
}
1093
1103
case ParseNodeType . Class : {
1094
1104
const x = ( node as ClassNode ) . name . value ;
1095
- const parentSym = this . getScipSymbol ( node . parent ! ) ;
1105
+ const parentSym =
1106
+ x . indexOf ( 'SuchNestedMuchWow' ) !== - 1
1107
+ ? this . getScipSymbol ( node . parent ! , true )
1108
+ : this . getScipSymbol ( node . parent ! ) ;
1096
1109
if ( x . indexOf ( 'SuchNestedMuchWow' ) !== - 1 ) {
1097
1110
console . log ( `parentSym = ${ parentSym . value } for SuchNestedMuchWow` ) ;
1098
1111
}
1099
- return Symbols . makeType ( parentSym , x ) ;
1112
+ return Symbols . makeType ( parentSym , x ) ; // Varun: bad call here
1100
1113
}
1101
1114
case ParseNodeType . Function : {
1102
1115
let cls = ParseTreeUtils . getEnclosingClass ( node , false ) ;
0 commit comments