Skip to content

Commit cbe718e

Browse files
committed
Remove Promise from typings
1 parent cedeb4e commit cbe718e

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

source-map.d.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -195,23 +195,23 @@ export interface SourceMapConsumerConstructor {
195195
GREATEST_LOWER_BOUND: number;
196196
LEAST_UPPER_BOUND: number;
197197

198-
new (rawSourceMap: RawSourceMap, sourceMapUrl?: SourceMapUrl): Promise<BasicSourceMapConsumer>;
199-
new (rawSourceMap: RawIndexMap, sourceMapUrl?: SourceMapUrl): Promise<IndexedSourceMapConsumer>;
200-
new (rawSourceMap: RawSourceMap | RawIndexMap | string, sourceMapUrl?: SourceMapUrl): Promise<
198+
new (rawSourceMap: RawSourceMap, sourceMapUrl?: SourceMapUrl): BasicSourceMapConsumer;
199+
new (rawSourceMap: RawIndexMap, sourceMapUrl?: SourceMapUrl): IndexedSourceMapConsumer;
200+
new (rawSourceMap: RawSourceMap | RawIndexMap | string, sourceMapUrl?: SourceMapUrl):
201201
BasicSourceMapConsumer | IndexedSourceMapConsumer
202-
>;
202+
;
203203

204204
/**
205205
* Create a BasicSourceMapConsumer from a SourceMapGenerator.
206206
*
207207
* @param sourceMap
208208
* The source map that will be consumed.
209209
*/
210-
fromSourceMap(sourceMap: SourceMapGenerator, sourceMapUrl?: SourceMapUrl): Promise<BasicSourceMapConsumer>;
210+
fromSourceMap(sourceMap: SourceMapGenerator, sourceMapUrl?: SourceMapUrl): BasicSourceMapConsumer;
211211

212212
/**
213213
* Construct a new `SourceMapConsumer` from `rawSourceMap` and `sourceMapUrl`
214-
* (see the `SourceMapConsumer` constructor for details. Then, invoke the `async
214+
* (see the `SourceMapConsumer` constructor for details. Then, invoke the `
215215
* function f(SourceMapConsumer) -> T` with the newly constructed consumer, wait
216216
* for `f` to complete, call `destroy` on the consumer, and return `f`'s return
217217
* value.
@@ -225,7 +225,7 @@ export interface SourceMapConsumerConstructor {
225225
* const xSquared = SourceMapConsumer.with(
226226
* myRawSourceMap,
227227
* null,
228-
* async function (consumer) {
228+
* function (consumer) {
229229
* // Use `consumer` inside here and don't worry about remembering
230230
* // to call `destroy`.
231231
*
@@ -242,8 +242,8 @@ export interface SourceMapConsumerConstructor {
242242
with<T>(
243243
rawSourceMap: RawSourceMap | RawIndexMap | string,
244244
sourceMapUrl: SourceMapUrl | null | undefined,
245-
callback: (consumer: BasicSourceMapConsumer | IndexedSourceMapConsumer) => Promise<T> | T
246-
): Promise<T>;
245+
callback: (consumer: BasicSourceMapConsumer | IndexedSourceMapConsumer) => T
246+
): T;
247247
}
248248

249249
export const SourceMapConsumer: SourceMapConsumerConstructor;
@@ -258,15 +258,15 @@ export interface BasicSourceMapConsumer extends SourceMapConsumer {
258258
export interface BasicSourceMapConsumerConstructor {
259259
prototype: BasicSourceMapConsumer;
260260

261-
new (rawSourceMap: RawSourceMap | string): Promise<BasicSourceMapConsumer>;
261+
new (rawSourceMap: RawSourceMap | string): BasicSourceMapConsumer;
262262

263263
/**
264264
* Create a BasicSourceMapConsumer from a SourceMapGenerator.
265265
*
266266
* @param sourceMap
267267
* The source map that will be consumed.
268268
*/
269-
fromSourceMap(sourceMap: SourceMapGenerator): Promise<BasicSourceMapConsumer>;
269+
fromSourceMap(sourceMap: SourceMapGenerator): BasicSourceMapConsumer;
270270
}
271271

272272
export const BasicSourceMapConsumer: BasicSourceMapConsumerConstructor;
@@ -278,7 +278,7 @@ export interface IndexedSourceMapConsumer extends SourceMapConsumer {
278278
export interface IndexedSourceMapConsumerConstructor {
279279
prototype: IndexedSourceMapConsumer;
280280

281-
new (rawSourceMap: RawIndexMap | string): Promise<IndexedSourceMapConsumer>;
281+
new (rawSourceMap: RawIndexMap | string): IndexedSourceMapConsumer;
282282
}
283283

284284
export const IndexedSourceMapConsumer: IndexedSourceMapConsumerConstructor;

0 commit comments

Comments
 (0)