change type of _serviceBrand from any to undefined, #79918

This commit is contained in:
Johannes Rieken
2019-08-30 15:35:48 +02:00
parent 1930ce78f8
commit dedf0de944
336 changed files with 511 additions and 551 deletions

View File

@@ -33,7 +33,7 @@ export interface ArgumentProcessor {
export class ExtHostCommands implements ExtHostCommandsShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private readonly _commands = new Map<string, CommandHandler>();
private readonly _proxy: MainThreadCommandsShape;

View File

@@ -42,7 +42,7 @@ type ConfigurationInspect<T> = {
export class ExtHostConfiguration implements ExtHostConfigurationShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private readonly _proxy: MainThreadConfigurationShape;
private readonly _extHostWorkspace: ExtHostWorkspace;

View File

@@ -13,7 +13,7 @@ export const IExtHostDebugService = createDecorator<IExtHostDebugService>('IExtH
export interface IExtHostDebugService extends ExtHostDebugServiceShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
onDidStartDebugSession: Event<vscode.DebugSession>;
onDidTerminateDebugSession: Event<vscode.DebugSession>;

View File

@@ -17,7 +17,7 @@ import { IExtHostRpcService } from 'vs/workbench/api/common/extHostRpcService';
export class ExtHostDocumentsAndEditors implements ExtHostDocumentsAndEditorsShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private _disposables: Disposable[] = [];

View File

@@ -64,7 +64,7 @@ type TelemetryActivationEventFragment = {
export abstract class AbstractExtHostExtensionService implements ExtHostExtensionServiceShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private static readonly WORKSPACE_CONTAINS_TIMEOUT = 7000;
@@ -767,7 +767,7 @@ function getTelemetryActivationEvent(extensionDescription: IExtensionDescription
export const IExtHostExtensionService = createDecorator<IExtHostExtensionService>('IExtHostExtensionService');
export interface IExtHostExtensionService extends AbstractExtHostExtensionService {
_serviceBrand: any;
_serviceBrand: undefined;
initialize(): Promise<void>;
isActivated(extensionId: ExtensionIdentifier): boolean;
activateByIdWithErrors(extensionId: ExtensionIdentifier, reason: ExtensionActivationReason): Promise<void>;

View File

@@ -137,7 +137,7 @@ export class LazyOutputChannel implements vscode.OutputChannel {
export class ExtHostOutputService implements ExtHostOutputServiceShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
protected readonly _proxy: MainThreadOutputServiceShape;

View File

@@ -9,11 +9,11 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'
export const IExtHostRpcService = createDecorator<IExtHostRpcService>('IExtHostRpcService');
export interface IExtHostRpcService extends IRPCProtocol {
_serviceBrand: any;
_serviceBrand: undefined;
}
export class ExtHostRpcService implements IExtHostRpcService {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
readonly getProxy: <T>(identifier: ProxyIdentifier<T>) => T;
readonly set: <T, R extends T> (identifier: ProxyIdentifier<T>, instance: R) => R;

View File

@@ -16,7 +16,7 @@ export interface IStorageChangeEvent {
export class ExtHostStorage implements ExtHostStorageShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private _proxy: MainThreadStorageShape;

View File

@@ -9,7 +9,7 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'
export const IExtensionStoragePaths = createDecorator<IExtensionStoragePaths>('IExtensionStoragePaths');
export interface IExtensionStoragePaths {
_serviceBrand: any;
_serviceBrand: undefined;
whenReady: Promise<any>;
workspaceValue(extension: IExtensionDescription): string | undefined;
globalValue(extension: IExtensionDescription): string;

View File

@@ -12,7 +12,7 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'
export interface IExtHostTask extends ExtHostTaskShape {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
taskExecutions: vscode.TaskExecution[];
onDidStartTask: Event<vscode.TaskStartEvent>;

View File

@@ -11,7 +11,7 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'
export interface IExtHostTerminalService extends ExtHostTerminalServiceShape {
_serviceBrand: any;
_serviceBrand: undefined;
activeTerminal: vscode.Terminal | undefined;
terminals: vscode.Terminal[];

View File

@@ -8,13 +8,13 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'
import { URI, UriComponents } from 'vs/base/common/uri';
export interface IURITransformerService extends IURITransformer {
_serviceBrand: any;
_serviceBrand: undefined;
}
export const IURITransformerService = createDecorator<IURITransformerService>('IURITransformerService');
export class URITransformerService implements IURITransformerService {
_serviceBrand: any;
_serviceBrand: undefined;
transformIncoming: (uri: UriComponents) => UriComponents;
transformOutgoing: (uri: UriComponents) => UriComponents;

View File

@@ -156,7 +156,7 @@ class ExtHostWorkspaceImpl extends Workspace {
export class ExtHostWorkspace implements ExtHostWorkspaceShape, IExtHostWorkspaceProvider {
readonly _serviceBrand: any;
readonly _serviceBrand: undefined;
private readonly _onDidChangeWorkspace = new Emitter<vscode.WorkspaceFoldersChangeEvent>();
readonly onDidChangeWorkspace: Event<vscode.WorkspaceFoldersChangeEvent> = this._onDidChangeWorkspace.event;