@@ -58,7 +58,7 @@ export class FunctionParser {
5858 // Parse method declarations in classes
5959 const classes = sourceFile . getClasses ( ) ;
6060 for ( const cls of classes ) {
61- let sym = cls . getSymbol ( ) ;
61+ const sym = cls . getSymbol ( ) ;
6262 let className = ""
6363 if ( sym ) {
6464 className = assignSymbolName ( sym )
@@ -104,7 +104,7 @@ export class FunctionParser {
104104 for ( const varDecl of variableDeclarations ) {
105105 const initializer = varDecl . getInitializer ( ) ;
106106 if ( initializer && ( Node . isArrowFunction ( initializer ) || Node . isFunctionExpression ( initializer ) ) ) {
107- let sym = varDecl . getSymbol ( )
107+ const sym = varDecl . getSymbol ( )
108108 let funcName = ""
109109 if ( sym ) {
110110 funcName = assignSymbolName ( sym )
@@ -140,7 +140,7 @@ export class FunctionParser {
140140 }
141141
142142 private parseFunction ( func : FunctionDeclaration , moduleName : string , packagePath : string , sourceFile : SourceFile ) : UniFunction {
143- let symbol = func . getSymbol ( ) ;
143+ const symbol = func . getSymbol ( ) ;
144144 let name = 'anonymous_' + func . getStart ( ) ;
145145 if ( symbol ) {
146146 name = assignSymbolName ( symbol )
@@ -189,7 +189,7 @@ export class FunctionParser {
189189 }
190190
191191 private parseMethod ( method : MethodDeclaration , moduleName : string , packagePath : string , sourceFile : SourceFile , className : string ) : UniFunction {
192- let symbol = method . getSymbol ( ) ;
192+ const symbol = method . getSymbol ( ) ;
193193 let methodName = ""
194194 if ( symbol ) {
195195 methodName = assignSymbolName ( symbol )
@@ -254,7 +254,7 @@ export class FunctionParser {
254254 }
255255
256256 private parseInterfaceMethod ( method : MethodSignature , moduleName : string , packagePath : string , sourceFile : SourceFile ) : UniFunction {
257- let symbol = method . getSymbol ( ) ;
257+ const symbol = method . getSymbol ( ) ;
258258 let methodName = ""
259259 if ( symbol ) {
260260 methodName = assignSymbolName ( symbol )
@@ -290,7 +290,7 @@ export class FunctionParser {
290290 }
291291
292292 private parseConstructor ( ctor : ConstructorDeclaration , moduleName : string , packagePath : string , sourceFile : SourceFile , className : string ) : UniFunction {
293- let symbol = ctor . getSymbol ( ) ;
293+ const symbol = ctor . getSymbol ( ) ;
294294 let name = ""
295295 if ( symbol ) {
296296 name = assignSymbolName ( symbol )
@@ -386,14 +386,14 @@ export class FunctionParser {
386386 }
387387
388388 // TODO: parse parameters
389- private parseParameters ( parameters : ParameterDeclaration [ ] , moduleName : string , packagePath : string , sourceFile : SourceFile ) : Dependency [ ] {
389+ private parseParameters ( _parameters : ParameterDeclaration [ ] , _moduleName : string , _packagePath : string , _sourceFile : SourceFile ) : Dependency [ ] {
390390 const dependencies : Dependency [ ] = [ ] ;
391391
392392 return dependencies ;
393393 }
394394
395395 // TODO: parse return types
396- private parseReturnTypes ( func : FunctionDeclaration | MethodSignature , moduleName : string , packagePath : string , sourceFile : SourceFile ) : Dependency [ ] {
396+ private parseReturnTypes ( _func : FunctionDeclaration | MethodSignature , _moduleName : string , _packagePath : string , _sourceFile : SourceFile ) : Dependency [ ] {
397397 const results : Dependency [ ] = [ ] ;
398398 return results ;
399399 }
@@ -402,7 +402,7 @@ export class FunctionParser {
402402 node : FunctionDeclaration | MethodDeclaration | ConstructorDeclaration | ArrowFunction | FunctionExpression ,
403403 moduleName : string ,
404404 packagePath : string ,
405- sourceFile : SourceFile
405+ _sourceFile : SourceFile
406406 ) : Dependency [ ] {
407407 const calls : Dependency [ ] = [ ] ;
408408 const visited = new Set < string > ( ) ;
@@ -429,7 +429,7 @@ export class FunctionParser {
429429 }
430430
431431 visited . add ( key ) ;
432- let dep : Dependency = {
432+ const dep : Dependency = {
433433 ModPath : resolvedSymbol . moduleName || moduleName ,
434434 PkgPath : this . getPkgPath ( resolvedSymbol . packagePath || packagePath ) ,
435435 Name : resolvedSymbol . name ,
@@ -509,7 +509,7 @@ export class FunctionParser {
509509 newExpr : Identifier ,
510510 moduleName : string ,
511511 packagePath : string ,
512- sourceFile : SourceFile ,
512+ _sourceFile : SourceFile ,
513513 calls : Dependency [ ] ,
514514 visited : Set < string >
515515 ) : void {
@@ -521,7 +521,7 @@ export class FunctionParser {
521521 if ( ! resolvedSymbol ) return ;
522522
523523 // Handle method names like 'getX' -> 'getX'
524- let nameFormat = resolvedSymbol . name ;
524+ const nameFormat = resolvedSymbol . name ;
525525
526526 const key = `${ resolvedSymbol . moduleName } ?${ resolvedSymbol . packagePath } #${ nameFormat } ` ;
527527
@@ -530,7 +530,7 @@ export class FunctionParser {
530530 }
531531 visited . add ( key ) ;
532532
533- let dep : Dependency = {
533+ const dep : Dependency = {
534534 ModPath : resolvedSymbol . moduleName || moduleName ,
535535 PkgPath : this . getPkgPath ( resolvedSymbol . packagePath || packagePath ) ,
536536 Name : nameFormat ,
@@ -566,7 +566,7 @@ export class FunctionParser {
566566 propAccess : PropertyAccessExpression ,
567567 moduleName : string ,
568568 packagePath : string ,
569- sourceFile : SourceFile ,
569+ _sourceFile : SourceFile ,
570570 calls : Dependency [ ] ,
571571 visited : Set < string >
572572 ) : void {
@@ -578,7 +578,7 @@ export class FunctionParser {
578578 if ( ! resolvedSymbol ) return ;
579579
580580 // Handle method names like 'getX' -> 'getX'
581- let nameFormat = resolvedSymbol . name ;
581+ const nameFormat = resolvedSymbol . name ;
582582
583583 const key = `${ resolvedSymbol . moduleName } ?${ resolvedSymbol . packagePath } #${ nameFormat } ` ;
584584
@@ -587,7 +587,7 @@ export class FunctionParser {
587587 }
588588 visited . add ( key ) ;
589589
590- let dep : Dependency = {
590+ const dep : Dependency = {
591591 ModPath : resolvedSymbol . moduleName || moduleName ,
592592 PkgPath : this . getPkgPath ( resolvedSymbol . packagePath || packagePath ) ,
593593 Name : nameFormat ,
@@ -623,7 +623,7 @@ export class FunctionParser {
623623 node : FunctionDeclaration | MethodDeclaration | ConstructorDeclaration | ArrowFunction | FunctionExpression ,
624624 moduleName : string ,
625625 packagePath : string ,
626- sourceFile : SourceFile
626+ _sourceFile : SourceFile
627627 ) : Dependency [ ] {
628628 const types : Dependency [ ] = [ ] ;
629629 const visited = new Set < string > ( ) ;
@@ -683,7 +683,7 @@ export class FunctionParser {
683683 }
684684
685685 visited . add ( key ) ;
686- let dep : Dependency = {
686+ const dep : Dependency = {
687687 ModPath : resolvedSymbol . moduleName || moduleName ,
688688 PkgPath : this . getPkgPath ( resolvedSymbol . packagePath || packagePath ) ,
689689 Name : resolvedSymbol . name ,
@@ -712,7 +712,7 @@ export class FunctionParser {
712712 node : FunctionDeclaration | MethodDeclaration | ConstructorDeclaration | ArrowFunction | FunctionExpression ,
713713 moduleName : string ,
714714 packagePath : string ,
715- sourceFile : SourceFile
715+ _sourceFile : SourceFile
716716 ) : Dependency [ ] {
717717 const body = node . getBody ( ) ;
718718 if ( ! body ) return [ ] ;
@@ -795,7 +795,7 @@ export class FunctionParser {
795795
796796 visited . add ( key ) ;
797797
798- let dep : Dependency = {
798+ const dep : Dependency = {
799799 ModPath : resolvedSymbol . moduleName || moduleName ,
800800 PkgPath : this . getPkgPath ( resolvedSymbol . packagePath || packagePath ) ,
801801 Name : resolvedSymbol . name ,
0 commit comments