@@ -491,7 +491,7 @@ namespace FourSlash {
491491 ] ;
492492 }
493493
494- private getAllDiagnostics ( ) : ts . Diagnostic [ ] {
494+ private getAllDiagnostics ( ) : ReadonlyArray < ts . Diagnostic > {
495495 return ts . flatMap ( this . languageServiceAdapterHost . getFilenames ( ) , fileName => {
496496 if ( ! ts . isAnySupportedFileExtension ( fileName ) ) {
497497 return [ ] ;
@@ -532,7 +532,7 @@ namespace FourSlash {
532532 predicate ( start ! , start ! + length ! , startMarker . position , endMarker === undefined ? undefined : endMarker . position ) ) ; // TODO: GH#18217
533533 }
534534
535- private printErrorLog ( expectErrors : boolean , errors : ts . Diagnostic [ ] ) {
535+ private printErrorLog ( expectErrors : boolean , errors : ReadonlyArray < ts . Diagnostic > ) : void {
536536 if ( expectErrors ) {
537537 Harness . IO . log ( "Expected error not found. Error list is:" ) ;
538538 }
@@ -613,7 +613,7 @@ namespace FourSlash {
613613 this . verifyGoToX ( arg0 , endMarkerNames , ( ) => this . getGoToDefinitionAndBoundSpan ( ) ) ;
614614 }
615615
616- private getGoToDefinition ( ) : ts . DefinitionInfo [ ] {
616+ private getGoToDefinition ( ) : ReadonlyArray < ts . DefinitionInfo > {
617617 return this . languageService . getDefinitionAtPosition ( this . activeFile . fileName , this . currentCaretPosition ) ! ;
618618 }
619619
@@ -626,7 +626,7 @@ namespace FourSlash {
626626 this . languageService . getTypeDefinitionAtPosition ( this . activeFile . fileName , this . currentCaretPosition ) ) ;
627627 }
628628
629- private verifyGoToX ( arg0 : any , endMarkerNames : ArrayOrSingle < string > | undefined , getDefs : ( ) => ts . DefinitionInfo [ ] | ts . DefinitionInfoAndBoundSpan | undefined ) {
629+ private verifyGoToX ( arg0 : any , endMarkerNames : ArrayOrSingle < string > | undefined , getDefs : ( ) => ReadonlyArray < ts . DefinitionInfo > | ts . DefinitionInfoAndBoundSpan | undefined ) {
630630 if ( endMarkerNames ) {
631631 this . verifyGoToXPlain ( arg0 , endMarkerNames , getDefs ) ;
632632 }
@@ -646,7 +646,7 @@ namespace FourSlash {
646646 }
647647 }
648648
649- private verifyGoToXPlain ( startMarkerNames : ArrayOrSingle < string > , endMarkerNames : ArrayOrSingle < string > , getDefs : ( ) => ts . DefinitionInfo [ ] | ts . DefinitionInfoAndBoundSpan | undefined ) {
649+ private verifyGoToXPlain ( startMarkerNames : ArrayOrSingle < string > , endMarkerNames : ArrayOrSingle < string > , getDefs : ( ) => ReadonlyArray < ts . DefinitionInfo > | ts . DefinitionInfoAndBoundSpan | undefined ) {
650650 for ( const start of toArray ( startMarkerNames ) ) {
651651 this . verifyGoToXSingle ( start , endMarkerNames , getDefs ) ;
652652 }
@@ -1890,7 +1890,7 @@ Actual: ${stringify(fullActual)}`);
18901890
18911891 public verifyRangesInImplementationList ( markerName : string ) {
18921892 this . goToMarker ( markerName ) ;
1893- const implementations : ImplementationLocationInformation [ ] = this . languageService . getImplementationAtPosition ( this . activeFile . fileName , this . currentCaretPosition ) ! ;
1893+ const implementations : ReadonlyArray < ImplementationLocationInformation > = this . languageService . getImplementationAtPosition ( this . activeFile . fileName , this . currentCaretPosition ) ! ;
18941894 if ( ! implementations || ! implementations . length ) {
18951895 this . raiseError ( "verifyRangesInImplementationList failed - expected to find at least one implementation location but got 0" ) ;
18961896 }
@@ -2383,7 +2383,7 @@ Actual: ${stringify(fullActual)}`);
23832383 * Rerieves a codefix satisfying the parameters, or undefined if no such codefix is found.
23842384 * @param fileName Path to file where error should be retrieved from.
23852385 */
2386- private getCodeFixes ( fileName : string , errorCode ?: number , preferences : ts . UserPreferences = ts . emptyOptions ) : ts . CodeFixAction [ ] {
2386+ private getCodeFixes ( fileName : string , errorCode ?: number , preferences : ts . UserPreferences = ts . emptyOptions ) : ReadonlyArray < ts . CodeFixAction > {
23872387 const diagnosticsForCodeFix = this . getDiagnostics ( fileName , /*includeSuggestions*/ true ) . map ( diagnostic => ( {
23882388 start : diagnostic . start ,
23892389 length : diagnostic . length ,
0 commit comments