@@ -1404,25 +1404,25 @@ namespace ts {
14041404 }
14051405
14061406 function findRenameLocations ( fileName : string , position : number , findInStrings : boolean , findInComments : boolean ) : RenameLocation [ ] {
1407- const referencedSymbols = findReferencedSymbols ( fileName , position , findInStrings , findInComments ) ;
1407+ const referencedSymbols = findReferencedSymbols ( fileName , position , findInStrings , findInComments , /*isForRename*/ true ) ;
14081408 return FindAllReferences . convertReferences ( referencedSymbols ) ;
14091409 }
14101410
14111411 function getReferencesAtPosition ( fileName : string , position : number ) : ReferenceEntry [ ] {
1412- const referencedSymbols = findReferencedSymbols ( fileName , position , /*findInStrings*/ false , /*findInComments*/ false ) ;
1412+ const referencedSymbols = findReferencedSymbols ( fileName , position , /*findInStrings*/ false , /*findInComments*/ false , /*isForRename*/ false ) ;
14131413 return FindAllReferences . convertReferences ( referencedSymbols ) ;
14141414 }
14151415
14161416 function findReferences ( fileName : string , position : number ) : ReferencedSymbol [ ] {
1417- const referencedSymbols = findReferencedSymbols ( fileName , position , /*findInStrings*/ false , /*findInComments*/ false ) ;
1417+ const referencedSymbols = findReferencedSymbols ( fileName , position , /*findInStrings*/ false , /*findInComments*/ false , /*isForRename*/ false ) ;
14181418
14191419 // Only include referenced symbols that have a valid definition.
14201420 return filter ( referencedSymbols , rs => ! ! rs . definition ) ;
14211421 }
14221422
1423- function findReferencedSymbols ( fileName : string , position : number , findInStrings : boolean , findInComments : boolean ) : ReferencedSymbol [ ] {
1423+ function findReferencedSymbols ( fileName : string , position : number , findInStrings : boolean , findInComments : boolean , isForRename : boolean ) : ReferencedSymbol [ ] {
14241424 synchronizeHostData ( ) ;
1425- return FindAllReferences . findReferencedSymbols ( program . getTypeChecker ( ) , cancellationToken , program . getSourceFiles ( ) , getValidSourceFile ( fileName ) , position , findInStrings , findInComments ) ;
1425+ return FindAllReferences . findReferencedSymbols ( program . getTypeChecker ( ) , cancellationToken , program . getSourceFiles ( ) , getValidSourceFile ( fileName ) , position , findInStrings , findInComments , isForRename ) ;
14261426 }
14271427
14281428 /// NavigateTo
0 commit comments