TS 3.4 formatting

This commit is contained in:
Matt Bierner
2019-04-03 11:43:49 -07:00
parent 86fe4b3b1c
commit b2cd559eb1
5 changed files with 8 additions and 8 deletions
@@ -95,7 +95,7 @@ export interface IInstantiationService {
/**
*
*/
invokeFunction<R, TS extends any[]=[]>(fn: (accessor: ServicesAccessor, ...args: TS) => R, ...args: TS): R;
invokeFunction<R, TS extends any[] = []>(fn: (accessor: ServicesAccessor, ...args: TS) => R, ...args: TS): R;
/**
* Creates a child of this service which inherts all current services
@@ -39,7 +39,7 @@ export class InstantiationService implements IInstantiationService {
return new InstantiationService(services, this._strict, this);
}
invokeFunction<R, TS extends any[]=[]>(fn: (accessor: ServicesAccessor, ...args: TS) => R, ...args: TS): R {
invokeFunction<R, TS extends any[] = []>(fn: (accessor: ServicesAccessor, ...args: TS) => R, ...args: TS): R {
let _trace = Trace.traceInvocation(fn);
let _done = false;
try {
+1 -1
View File
@@ -52,7 +52,7 @@ export interface IProgressService2 {
_serviceBrand: any;
withProgress<R=any>(options: IProgressOptions, task: (progress: IProgress<IProgressStep>) => Promise<R>, onDidCancel?: () => void): Promise<R>;
withProgress<R = any>(options: IProgressOptions, task: (progress: IProgress<IProgressStep>) => Promise<R>, onDidCancel?: () => void): Promise<R>;
}
export interface IProgressRunner {
@@ -31,7 +31,7 @@ export class ProgressService2 implements IProgressService2 {
@IStatusbarService private readonly _statusbarService: IStatusbarService,
) { }
withProgress<R=unknown>(options: IProgressOptions, task: (progress: IProgress<IProgressStep>) => Promise<R>, onDidCancel?: () => void): Promise<R> {
withProgress<R = unknown>(options: IProgressOptions, task: (progress: IProgress<IProgressStep>) => Promise<R>, onDidCancel?: () => void): Promise<R> {
const { location } = options;
if (typeof location === 'string') {
@@ -58,7 +58,7 @@ export class ProgressService2 implements IProgressService2 {
}
}
private _withWindowProgress<R=unknown>(options: IProgressOptions, callback: (progress: IProgress<{ message?: string }>) => Promise<R>): Promise<R> {
private _withWindowProgress<R = unknown>(options: IProgressOptions, callback: (progress: IProgress<{ message?: string }>) => Promise<R>): Promise<R> {
const task: [IProgressOptions, Progress<IProgressStep>] = [options, new Progress<IProgressStep>(() => this._updateWindowProgress())];
@@ -126,7 +126,7 @@ export class ProgressService2 implements IProgressService2 {
}
}
private _withNotificationProgress<P extends Promise<R>, R=unknown>(options: IProgressOptions, callback: (progress: IProgress<{ message?: string, increment?: number }>) => P, onDidCancel?: () => void): P {
private _withNotificationProgress<P extends Promise<R>, R = unknown>(options: IProgressOptions, callback: (progress: IProgress<{ message?: string, increment?: number }>) => P, onDidCancel?: () => void): P {
const toDispose: IDisposable[] = [];
const createNotification = (message: string | undefined, increment?: number): INotificationHandle | undefined => {
@@ -221,7 +221,7 @@ export class ProgressService2 implements IProgressService2 {
return p;
}
private _withViewletProgress<P extends Promise<R>, R=unknown>(viewletId: string, task: (progress: IProgress<{ message?: string }>) => P): P {
private _withViewletProgress<P extends Promise<R>, R = unknown>(viewletId: string, task: (progress: IProgress<{ message?: string }>) => P): P {
const promise = task(emptyProgress);
@@ -53,7 +53,7 @@ export interface ISearchResultProvider {
clearCache(cacheKey: string): Promise<void>;
}
export interface IFolderQuery<U extends UriComponents=URI> {
export interface IFolderQuery<U extends UriComponents = URI> {
folder: U;
excludePattern?: glob.IExpression;
includePattern?: glob.IExpression;