core icon indicating copy to clipboard operation
core copied to clipboard

Unnecessary generic parameter for Task.race

Open jason0x43 opened this issue 8 years ago • 0 comments

Bug

Task.race takes two generic parameters, an ExtensiblePromise subclass and the type expected to be the resolution of the race call. The first parameter is unnecessary as it is never used within the Task class.

Package Version: beta1

Code

const task = Task.race<void>([ ... ]);

Expected behavior:

This should compile.

Actual behavior:

TS complains that the call signature is invalid. The following does compile:

const task = Task.race<Task<void>, void>([ ... ]);

jason0x43 avatar Apr 08 '17 15:04 jason0x43