mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-23 07:07:09 -05:00
Unnecessary elaboration about not being assignable to type parameters (#42952)
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
// @lib: es2015
|
||||
// @target: ES5
|
||||
async function foo<T>(x: T): Promise<T> {
|
||||
let yaddable = await getXOrYadda(x);
|
||||
return yaddable;
|
||||
}
|
||||
|
||||
interface Yadda {
|
||||
stuff: string,
|
||||
things: string,
|
||||
}
|
||||
|
||||
declare function getXOrYadda<T>(x: T): T | Yadda;
|
||||
Reference in New Issue
Block a user