File tree Expand file tree Collapse file tree
css-language-features/client/src
html-language-features/client/src
typescript-language-features/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ interface ExperimentalConfig {
1313 } ;
1414}
1515
16- export function getCustomDataPathsInAllWorkspaces ( workspaceFolders : WorkspaceFolder [ ] | undefined ) : string [ ] {
16+ export function getCustomDataPathsInAllWorkspaces ( workspaceFolders : readonly WorkspaceFolder [ ] | undefined ) : string [ ] {
1717 const dataPaths : string [ ] = [ ] ;
1818
1919 if ( ! workspaceFolders ) {
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ interface ExperimentalConfig {
1313 } ;
1414}
1515
16- export function getCustomDataPathsInAllWorkspaces ( workspaceFolders : WorkspaceFolder [ ] | undefined ) : string [ ] {
16+ export function getCustomDataPathsInAllWorkspaces ( workspaceFolders : readonly WorkspaceFolder [ ] | undefined ) : string [ ] {
1717 const dataPaths : string [ ] = [ ] ;
1818
1919 if ( ! workspaceFolders ) {
Original file line number Diff line number Diff line change @@ -634,7 +634,7 @@ export default class TypeScriptServiceClient extends Disposable implements IType
634634 }
635635
636636 public getWorkspaceRootForResource ( resource : vscode . Uri ) : string | undefined {
637- const roots = vscode . workspace . workspaceFolders ;
637+ const roots = vscode . workspace . workspaceFolders ? Array . from ( vscode . workspace . workspaceFolders ) : undefined ;
638638 if ( ! roots || ! roots . length ) {
639639 return undefined ;
640640 }
Original file line number Diff line number Diff line change @@ -8435,7 +8435,7 @@ declare module 'vscode' {
84358435 * List of workspace folders or `undefined` when no folder is open.
84368436 * *Note* that the first entry corresponds to the value of `rootPath`.
84378437 */
8438- export const workspaceFolders : WorkspaceFolder [ ] | undefined ;
8438+ export const workspaceFolders : ReadonlyArray < WorkspaceFolder > | undefined ;
84398439
84408440 /**
84418441 * The name of the workspace. `undefined` when no folder
@@ -8609,7 +8609,7 @@ declare module 'vscode' {
86098609 /**
86108610 * All text documents currently known to the system.
86118611 */
8612- export const textDocuments : TextDocument [ ] ;
8612+ export const textDocuments : ReadonlyArray < TextDocument > ;
86138613
86148614 /**
86158615 * Opens a document. Will return early if this document is already open. Otherwise
You can’t perform that action at this time.
0 commit comments