mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-14 10:55:15 -06:00
Accept new baselines
This commit is contained in:
parent
d2cc282134
commit
4d67c8f873
@ -1,35 +1,40 @@
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(6,35): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(9,11): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(10,35): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(11,11): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(14,32): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(11,35): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(17,11): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(18,35): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(19,11): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(22,32): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
Property '1' is missing in type '[number]' but required in type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(15,37): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(16,32): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(23,37): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(24,32): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
Types of property 'length' are incompatible.
|
||||
Type '3' is not assignable to type '2'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(29,29): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(30,22): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(33,11): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(34,29): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(35,11): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(36,22): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(39,26): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(40,31): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(41,26): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(42,23): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(47,33): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(50,1): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(51,15): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(52,1): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(55,12): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(56,17): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(57,12): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(41,29): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(42,22): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(48,11): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(49,29): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(50,11): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(51,22): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(54,26): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(55,31): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(56,26): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(57,23): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(62,33): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(65,1): error TS2554: Expected 3 arguments, but got 2.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(66,15): error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(67,1): error TS2554: Expected 3 arguments, but got 4.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(70,12): error TS2345: Argument of type '[number]' is not assignable to parameter of type '[number, string]'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(71,17): error TS2322: Type 'number' is not assignable to type 'string'.
|
||||
tests/cases/conformance/functions/strictBindCallApply1.ts(72,12): error TS2345: Argument of type '[number, string, number]' is not assignable to parameter of type '[number, string]'.
|
||||
|
||||
|
||||
==== tests/cases/conformance/functions/strictBindCallApply1.ts (24 errors) ====
|
||||
declare function foo(a: number, b: string): string;
|
||||
|
||||
declare function overloaded(s: string): number;
|
||||
declare function overloaded(n: number): string;
|
||||
|
||||
declare function generic<T>(x: T): T;
|
||||
|
||||
let f00 = foo.bind(undefined);
|
||||
let f01 = foo.bind(undefined, 10);
|
||||
let f02 = foo.bind(undefined, 10, "hello");
|
||||
@ -37,6 +42,9 @@ tests/cases/conformance/functions/strictBindCallApply1.ts(57,12): error TS2345:
|
||||
~~
|
||||
!!! error TS2345: Argument of type '20' is not assignable to parameter of type 'string'.
|
||||
|
||||
let f04 = overloaded.bind(undefined); // typeof overloaded
|
||||
let f05 = generic.bind(undefined); // typeof generic
|
||||
|
||||
let c00 = foo.call(undefined, 10, "hello");
|
||||
let c01 = foo.call(undefined, 10); // Error
|
||||
~~~~~~~~~~~~~~~~~~~~~~~
|
||||
@ -65,6 +73,10 @@ tests/cases/conformance/functions/strictBindCallApply1.ts(57,12): error TS2345:
|
||||
class C {
|
||||
constructor(a: number, b: string) {}
|
||||
foo(this: this, a: number, b: string): string { return "" }
|
||||
overloaded(s: string): number;
|
||||
overloaded(n: number): string;
|
||||
overloaded(x: any): any { return <any>undefined }
|
||||
generic<T>(x: T): T { return x }
|
||||
}
|
||||
|
||||
declare let c: C;
|
||||
@ -80,6 +92,9 @@ tests/cases/conformance/functions/strictBindCallApply1.ts(57,12): error TS2345:
|
||||
~~~~~~~~~
|
||||
!!! error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'C'.
|
||||
|
||||
let f15 = c.overloaded.bind(c); // typeof C.prototype.overloaded
|
||||
let f16 = c.generic.bind(c); // typeof C.prototype.generic
|
||||
|
||||
let c10 = c.foo.call(c, 10, "hello");
|
||||
let c11 = c.foo.call(c, 10); // Error
|
||||
~~~~~~~~~~~~~~~~~
|
||||
|
||||
@ -1,11 +1,19 @@
|
||||
//// [strictBindCallApply1.ts]
|
||||
declare function foo(a: number, b: string): string;
|
||||
|
||||
declare function overloaded(s: string): number;
|
||||
declare function overloaded(n: number): string;
|
||||
|
||||
declare function generic<T>(x: T): T;
|
||||
|
||||
let f00 = foo.bind(undefined);
|
||||
let f01 = foo.bind(undefined, 10);
|
||||
let f02 = foo.bind(undefined, 10, "hello");
|
||||
let f03 = foo.bind(undefined, 10, 20); // Error
|
||||
|
||||
let f04 = overloaded.bind(undefined); // typeof overloaded
|
||||
let f05 = generic.bind(undefined); // typeof generic
|
||||
|
||||
let c00 = foo.call(undefined, 10, "hello");
|
||||
let c01 = foo.call(undefined, 10); // Error
|
||||
let c02 = foo.call(undefined, 10, 20); // Error
|
||||
@ -19,6 +27,10 @@ let a03 = foo.apply(undefined, [10, "hello", 30]); // Error
|
||||
class C {
|
||||
constructor(a: number, b: string) {}
|
||||
foo(this: this, a: number, b: string): string { return "" }
|
||||
overloaded(s: string): number;
|
||||
overloaded(n: number): string;
|
||||
overloaded(x: any): any { return <any>undefined }
|
||||
generic<T>(x: T): T { return x }
|
||||
}
|
||||
|
||||
declare let c: C;
|
||||
@ -30,6 +42,9 @@ let f12 = c.foo.bind(c, 10, "hello");
|
||||
let f13 = c.foo.bind(c, 10, 20); // Error
|
||||
let f14 = c.foo.bind(undefined); // Error
|
||||
|
||||
let f15 = c.overloaded.bind(c); // typeof C.prototype.overloaded
|
||||
let f16 = c.generic.bind(c); // typeof C.prototype.generic
|
||||
|
||||
let c10 = c.foo.call(c, 10, "hello");
|
||||
let c11 = c.foo.call(c, 10); // Error
|
||||
let c12 = c.foo.call(c, 10, 20); // Error
|
||||
@ -64,6 +79,8 @@ var f00 = foo.bind(undefined);
|
||||
var f01 = foo.bind(undefined, 10);
|
||||
var f02 = foo.bind(undefined, 10, "hello");
|
||||
var f03 = foo.bind(undefined, 10, 20); // Error
|
||||
var f04 = overloaded.bind(undefined); // typeof overloaded
|
||||
var f05 = generic.bind(undefined); // typeof generic
|
||||
var c00 = foo.call(undefined, 10, "hello");
|
||||
var c01 = foo.call(undefined, 10); // Error
|
||||
var c02 = foo.call(undefined, 10, 20); // Error
|
||||
@ -76,6 +93,8 @@ var C = /** @class */ (function () {
|
||||
function C(a, b) {
|
||||
}
|
||||
C.prototype.foo = function (a, b) { return ""; };
|
||||
C.prototype.overloaded = function (x) { return undefined; };
|
||||
C.prototype.generic = function (x) { return x; };
|
||||
return C;
|
||||
}());
|
||||
var f10 = c.foo.bind(c);
|
||||
@ -83,6 +102,8 @@ var f11 = c.foo.bind(c, 10);
|
||||
var f12 = c.foo.bind(c, 10, "hello");
|
||||
var f13 = c.foo.bind(c, 10, 20); // Error
|
||||
var f14 = c.foo.bind(undefined); // Error
|
||||
var f15 = c.overloaded.bind(c); // typeof C.prototype.overloaded
|
||||
var f16 = c.generic.bind(c); // typeof C.prototype.generic
|
||||
var c10 = c.foo.call(c, 10, "hello");
|
||||
var c11 = c.foo.call(c, 10); // Error
|
||||
var c12 = c.foo.call(c, 10, 20); // Error
|
||||
|
||||
@ -4,319 +4,387 @@ declare function foo(a: number, b: string): string;
|
||||
>a : Symbol(a, Decl(strictBindCallApply1.ts, 0, 21))
|
||||
>b : Symbol(b, Decl(strictBindCallApply1.ts, 0, 31))
|
||||
|
||||
declare function overloaded(s: string): number;
|
||||
>overloaded : Symbol(overloaded, Decl(strictBindCallApply1.ts, 0, 51), Decl(strictBindCallApply1.ts, 2, 47))
|
||||
>s : Symbol(s, Decl(strictBindCallApply1.ts, 2, 28))
|
||||
|
||||
declare function overloaded(n: number): string;
|
||||
>overloaded : Symbol(overloaded, Decl(strictBindCallApply1.ts, 0, 51), Decl(strictBindCallApply1.ts, 2, 47))
|
||||
>n : Symbol(n, Decl(strictBindCallApply1.ts, 3, 28))
|
||||
|
||||
declare function generic<T>(x: T): T;
|
||||
>generic : Symbol(generic, Decl(strictBindCallApply1.ts, 3, 47))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 5, 25))
|
||||
>x : Symbol(x, Decl(strictBindCallApply1.ts, 5, 28))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 5, 25))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 5, 25))
|
||||
|
||||
let f00 = foo.bind(undefined);
|
||||
>f00 : Symbol(f00, Decl(strictBindCallApply1.ts, 2, 3))
|
||||
>f00 : Symbol(f00, Decl(strictBindCallApply1.ts, 7, 3))
|
||||
>foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f01 = foo.bind(undefined, 10);
|
||||
>f01 : Symbol(f01, Decl(strictBindCallApply1.ts, 3, 3))
|
||||
>f01 : Symbol(f01, Decl(strictBindCallApply1.ts, 8, 3))
|
||||
>foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f02 = foo.bind(undefined, 10, "hello");
|
||||
>f02 : Symbol(f02, Decl(strictBindCallApply1.ts, 4, 3))
|
||||
>f02 : Symbol(f02, Decl(strictBindCallApply1.ts, 9, 3))
|
||||
>foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f03 = foo.bind(undefined, 10, 20); // Error
|
||||
>f03 : Symbol(f03, Decl(strictBindCallApply1.ts, 5, 3))
|
||||
>f03 : Symbol(f03, Decl(strictBindCallApply1.ts, 10, 3))
|
||||
>foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f04 = overloaded.bind(undefined); // typeof overloaded
|
||||
>f04 : Symbol(f04, Decl(strictBindCallApply1.ts, 12, 3))
|
||||
>overloaded.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>overloaded : Symbol(overloaded, Decl(strictBindCallApply1.ts, 0, 51), Decl(strictBindCallApply1.ts, 2, 47))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f05 = generic.bind(undefined); // typeof generic
|
||||
>f05 : Symbol(f05, Decl(strictBindCallApply1.ts, 13, 3))
|
||||
>generic.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>generic : Symbol(generic, Decl(strictBindCallApply1.ts, 3, 47))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let c00 = foo.call(undefined, 10, "hello");
|
||||
>c00 : Symbol(c00, Decl(strictBindCallApply1.ts, 7, 3))
|
||||
>c00 : Symbol(c00, Decl(strictBindCallApply1.ts, 15, 3))
|
||||
>foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let c01 = foo.call(undefined, 10); // Error
|
||||
>c01 : Symbol(c01, Decl(strictBindCallApply1.ts, 8, 3))
|
||||
>c01 : Symbol(c01, Decl(strictBindCallApply1.ts, 16, 3))
|
||||
>foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let c02 = foo.call(undefined, 10, 20); // Error
|
||||
>c02 : Symbol(c02, Decl(strictBindCallApply1.ts, 9, 3))
|
||||
>c02 : Symbol(c02, Decl(strictBindCallApply1.ts, 17, 3))
|
||||
>foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let c03 = foo.call(undefined, 10, "hello", 30); // Error
|
||||
>c03 : Symbol(c03, Decl(strictBindCallApply1.ts, 10, 3))
|
||||
>c03 : Symbol(c03, Decl(strictBindCallApply1.ts, 18, 3))
|
||||
>foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let a00 = foo.apply(undefined, [10, "hello"]);
|
||||
>a00 : Symbol(a00, Decl(strictBindCallApply1.ts, 12, 3))
|
||||
>a00 : Symbol(a00, Decl(strictBindCallApply1.ts, 20, 3))
|
||||
>foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let a01 = foo.apply(undefined, [10]); // Error
|
||||
>a01 : Symbol(a01, Decl(strictBindCallApply1.ts, 13, 3))
|
||||
>a01 : Symbol(a01, Decl(strictBindCallApply1.ts, 21, 3))
|
||||
>foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let a02 = foo.apply(undefined, [10, 20]); // Error
|
||||
>a02 : Symbol(a02, Decl(strictBindCallApply1.ts, 14, 3))
|
||||
>a02 : Symbol(a02, Decl(strictBindCallApply1.ts, 22, 3))
|
||||
>foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let a03 = foo.apply(undefined, [10, "hello", 30]); // Error
|
||||
>a03 : Symbol(a03, Decl(strictBindCallApply1.ts, 15, 3))
|
||||
>a03 : Symbol(a03, Decl(strictBindCallApply1.ts, 23, 3))
|
||||
>foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>foo : Symbol(foo, Decl(strictBindCallApply1.ts, 0, 0))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
class C {
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
|
||||
constructor(a: number, b: string) {}
|
||||
>a : Symbol(a, Decl(strictBindCallApply1.ts, 18, 16))
|
||||
>b : Symbol(b, Decl(strictBindCallApply1.ts, 18, 26))
|
||||
>a : Symbol(a, Decl(strictBindCallApply1.ts, 26, 16))
|
||||
>b : Symbol(b, Decl(strictBindCallApply1.ts, 26, 26))
|
||||
|
||||
foo(this: this, a: number, b: string): string { return "" }
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>this : Symbol(this, Decl(strictBindCallApply1.ts, 19, 8))
|
||||
>a : Symbol(a, Decl(strictBindCallApply1.ts, 19, 19))
|
||||
>b : Symbol(b, Decl(strictBindCallApply1.ts, 19, 30))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>this : Symbol(this, Decl(strictBindCallApply1.ts, 27, 8))
|
||||
>a : Symbol(a, Decl(strictBindCallApply1.ts, 27, 19))
|
||||
>b : Symbol(b, Decl(strictBindCallApply1.ts, 27, 30))
|
||||
|
||||
overloaded(s: string): number;
|
||||
>overloaded : Symbol(C.overloaded, Decl(strictBindCallApply1.ts, 27, 63), Decl(strictBindCallApply1.ts, 28, 34), Decl(strictBindCallApply1.ts, 29, 34))
|
||||
>s : Symbol(s, Decl(strictBindCallApply1.ts, 28, 15))
|
||||
|
||||
overloaded(n: number): string;
|
||||
>overloaded : Symbol(C.overloaded, Decl(strictBindCallApply1.ts, 27, 63), Decl(strictBindCallApply1.ts, 28, 34), Decl(strictBindCallApply1.ts, 29, 34))
|
||||
>n : Symbol(n, Decl(strictBindCallApply1.ts, 29, 15))
|
||||
|
||||
overloaded(x: any): any { return <any>undefined }
|
||||
>overloaded : Symbol(C.overloaded, Decl(strictBindCallApply1.ts, 27, 63), Decl(strictBindCallApply1.ts, 28, 34), Decl(strictBindCallApply1.ts, 29, 34))
|
||||
>x : Symbol(x, Decl(strictBindCallApply1.ts, 30, 15))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
generic<T>(x: T): T { return x }
|
||||
>generic : Symbol(C.generic, Decl(strictBindCallApply1.ts, 30, 53))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 31, 12))
|
||||
>x : Symbol(x, Decl(strictBindCallApply1.ts, 31, 15))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 31, 12))
|
||||
>T : Symbol(T, Decl(strictBindCallApply1.ts, 31, 12))
|
||||
>x : Symbol(x, Decl(strictBindCallApply1.ts, 31, 15))
|
||||
}
|
||||
|
||||
declare let c: C;
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
|
||||
declare let obj: {};
|
||||
>obj : Symbol(obj, Decl(strictBindCallApply1.ts, 23, 11))
|
||||
>obj : Symbol(obj, Decl(strictBindCallApply1.ts, 35, 11))
|
||||
|
||||
let f10 = c.foo.bind(c);
|
||||
>f10 : Symbol(f10, Decl(strictBindCallApply1.ts, 25, 3))
|
||||
>f10 : Symbol(f10, Decl(strictBindCallApply1.ts, 37, 3))
|
||||
>c.foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let f11 = c.foo.bind(c, 10);
|
||||
>f11 : Symbol(f11, Decl(strictBindCallApply1.ts, 26, 3))
|
||||
>f11 : Symbol(f11, Decl(strictBindCallApply1.ts, 38, 3))
|
||||
>c.foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let f12 = c.foo.bind(c, 10, "hello");
|
||||
>f12 : Symbol(f12, Decl(strictBindCallApply1.ts, 27, 3))
|
||||
>f12 : Symbol(f12, Decl(strictBindCallApply1.ts, 39, 3))
|
||||
>c.foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let f13 = c.foo.bind(c, 10, 20); // Error
|
||||
>f13 : Symbol(f13, Decl(strictBindCallApply1.ts, 28, 3))
|
||||
>f13 : Symbol(f13, Decl(strictBindCallApply1.ts, 40, 3))
|
||||
>c.foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let f14 = c.foo.bind(undefined); // Error
|
||||
>f14 : Symbol(f14, Decl(strictBindCallApply1.ts, 29, 3))
|
||||
>f14 : Symbol(f14, Decl(strictBindCallApply1.ts, 41, 3))
|
||||
>c.foo.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f15 = c.overloaded.bind(c); // typeof C.prototype.overloaded
|
||||
>f15 : Symbol(f15, Decl(strictBindCallApply1.ts, 43, 3))
|
||||
>c.overloaded.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.overloaded : Symbol(C.overloaded, Decl(strictBindCallApply1.ts, 27, 63), Decl(strictBindCallApply1.ts, 28, 34), Decl(strictBindCallApply1.ts, 29, 34))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>overloaded : Symbol(C.overloaded, Decl(strictBindCallApply1.ts, 27, 63), Decl(strictBindCallApply1.ts, 28, 34), Decl(strictBindCallApply1.ts, 29, 34))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let f16 = c.generic.bind(c); // typeof C.prototype.generic
|
||||
>f16 : Symbol(f16, Decl(strictBindCallApply1.ts, 44, 3))
|
||||
>c.generic.bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c.generic : Symbol(C.generic, Decl(strictBindCallApply1.ts, 30, 53))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>generic : Symbol(C.generic, Decl(strictBindCallApply1.ts, 30, 53))
|
||||
>bind : Symbol(CallableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let c10 = c.foo.call(c, 10, "hello");
|
||||
>c10 : Symbol(c10, Decl(strictBindCallApply1.ts, 31, 3))
|
||||
>c10 : Symbol(c10, Decl(strictBindCallApply1.ts, 46, 3))
|
||||
>c.foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let c11 = c.foo.call(c, 10); // Error
|
||||
>c11 : Symbol(c11, Decl(strictBindCallApply1.ts, 32, 3))
|
||||
>c11 : Symbol(c11, Decl(strictBindCallApply1.ts, 47, 3))
|
||||
>c.foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let c12 = c.foo.call(c, 10, 20); // Error
|
||||
>c12 : Symbol(c12, Decl(strictBindCallApply1.ts, 33, 3))
|
||||
>c12 : Symbol(c12, Decl(strictBindCallApply1.ts, 48, 3))
|
||||
>c.foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let c13 = c.foo.call(c, 10, "hello", 30); // Error
|
||||
>c13 : Symbol(c13, Decl(strictBindCallApply1.ts, 34, 3))
|
||||
>c13 : Symbol(c13, Decl(strictBindCallApply1.ts, 49, 3))
|
||||
>c.foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let c14 = c.foo.call(undefined, 10, "hello"); // Error
|
||||
>c14 : Symbol(c14, Decl(strictBindCallApply1.ts, 35, 3))
|
||||
>c14 : Symbol(c14, Decl(strictBindCallApply1.ts, 50, 3))
|
||||
>c.foo.call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>call : Symbol(CallableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let a10 = c.foo.apply(c, [10, "hello"]);
|
||||
>a10 : Symbol(a10, Decl(strictBindCallApply1.ts, 37, 3))
|
||||
>a10 : Symbol(a10, Decl(strictBindCallApply1.ts, 52, 3))
|
||||
>c.foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let a11 = c.foo.apply(c, [10]); // Error
|
||||
>a11 : Symbol(a11, Decl(strictBindCallApply1.ts, 38, 3))
|
||||
>a11 : Symbol(a11, Decl(strictBindCallApply1.ts, 53, 3))
|
||||
>c.foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let a12 = c.foo.apply(c, [10, 20]); // Error
|
||||
>a12 : Symbol(a12, Decl(strictBindCallApply1.ts, 39, 3))
|
||||
>a12 : Symbol(a12, Decl(strictBindCallApply1.ts, 54, 3))
|
||||
>c.foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let a13 = c.foo.apply(c, [10, "hello", 30]); // Error
|
||||
>a13 : Symbol(a13, Decl(strictBindCallApply1.ts, 40, 3))
|
||||
>a13 : Symbol(a13, Decl(strictBindCallApply1.ts, 55, 3))
|
||||
>c.foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
let a14 = c.foo.apply(undefined, [10, "hello"]); // Error
|
||||
>a14 : Symbol(a14, Decl(strictBindCallApply1.ts, 41, 3))
|
||||
>a14 : Symbol(a14, Decl(strictBindCallApply1.ts, 56, 3))
|
||||
>c.foo.apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 18, 40))
|
||||
>c.foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
>foo : Symbol(C.foo, Decl(strictBindCallApply1.ts, 26, 40))
|
||||
>apply : Symbol(CallableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f20 = C.bind(undefined);
|
||||
>f20 : Symbol(f20, Decl(strictBindCallApply1.ts, 43, 3))
|
||||
>f20 : Symbol(f20, Decl(strictBindCallApply1.ts, 58, 3))
|
||||
>C.bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f21 = C.bind(undefined, 10);
|
||||
>f21 : Symbol(f21, Decl(strictBindCallApply1.ts, 44, 3))
|
||||
>f21 : Symbol(f21, Decl(strictBindCallApply1.ts, 59, 3))
|
||||
>C.bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f22 = C.bind(undefined, 10, "hello");
|
||||
>f22 : Symbol(f22, Decl(strictBindCallApply1.ts, 45, 3))
|
||||
>f22 : Symbol(f22, Decl(strictBindCallApply1.ts, 60, 3))
|
||||
>C.bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
let f23 = C.bind(undefined, 10, 20); // Error
|
||||
>f23 : Symbol(f23, Decl(strictBindCallApply1.ts, 46, 3))
|
||||
>f23 : Symbol(f23, Decl(strictBindCallApply1.ts, 61, 3))
|
||||
>C.bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>bind : Symbol(NewableFunction.bind, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --) ... and 1 more)
|
||||
>undefined : Symbol(undefined)
|
||||
|
||||
C.call(c, 10, "hello");
|
||||
>C.call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.call(c, 10); // Error
|
||||
>C.call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.call(c, 10, 20); // Error
|
||||
>C.call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.call(c, 10, "hello", 30); // Error
|
||||
>C.call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>call : Symbol(NewableFunction.call, Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.apply(c, [10, "hello"]);
|
||||
>C.apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.apply(c, [10]); // Error
|
||||
>C.apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.apply(c, [10, 20]); // Error
|
||||
>C.apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
C.apply(c, [10, "hello", 30]); // Error
|
||||
>C.apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 15, 50))
|
||||
>C : Symbol(C, Decl(strictBindCallApply1.ts, 23, 50))
|
||||
>apply : Symbol(NewableFunction.apply, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 22, 11))
|
||||
>c : Symbol(c, Decl(strictBindCallApply1.ts, 34, 11))
|
||||
|
||||
|
||||
@ -4,6 +4,18 @@ declare function foo(a: number, b: string): string;
|
||||
>a : number
|
||||
>b : string
|
||||
|
||||
declare function overloaded(s: string): number;
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>s : string
|
||||
|
||||
declare function overloaded(n: number): string;
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>n : number
|
||||
|
||||
declare function generic<T>(x: T): T;
|
||||
>generic : <T>(x: T) => T
|
||||
>x : T
|
||||
|
||||
let f00 = foo.bind(undefined);
|
||||
>f00 : (a: number, b: string) => string
|
||||
>foo.bind(undefined) : (a: number, b: string) => string
|
||||
@ -41,6 +53,22 @@ let f03 = foo.bind(undefined, 10, 20); // Error
|
||||
>10 : 10
|
||||
>20 : 20
|
||||
|
||||
let f04 = overloaded.bind(undefined); // typeof overloaded
|
||||
>f04 : { (s: string): number; (n: number): string; }
|
||||
>overloaded.bind(undefined) : { (s: string): number; (n: number): string; }
|
||||
>overloaded.bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>undefined : undefined
|
||||
|
||||
let f05 = generic.bind(undefined); // typeof generic
|
||||
>f05 : <T>(x: T) => T
|
||||
>generic.bind(undefined) : <T>(x: T) => T
|
||||
>generic.bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>generic : <T>(x: T) => T
|
||||
>bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>undefined : undefined
|
||||
|
||||
let c00 = foo.call(undefined, 10, "hello");
|
||||
>c00 : string
|
||||
>foo.call(undefined, 10, "hello") : string
|
||||
@ -138,6 +166,25 @@ class C {
|
||||
>a : number
|
||||
>b : string
|
||||
>"" : ""
|
||||
|
||||
overloaded(s: string): number;
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>s : string
|
||||
|
||||
overloaded(n: number): string;
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>n : number
|
||||
|
||||
overloaded(x: any): any { return <any>undefined }
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>x : any
|
||||
><any>undefined : any
|
||||
>undefined : undefined
|
||||
|
||||
generic<T>(x: T): T { return x }
|
||||
>generic : <T>(x: T) => T
|
||||
>x : T
|
||||
>x : T
|
||||
}
|
||||
|
||||
declare let c: C;
|
||||
@ -201,6 +248,26 @@ let f14 = c.foo.bind(undefined); // Error
|
||||
>bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>undefined : undefined
|
||||
|
||||
let f15 = c.overloaded.bind(c); // typeof C.prototype.overloaded
|
||||
>f15 : { (s: string): number; (n: number): string; }
|
||||
>c.overloaded.bind(c) : { (s: string): number; (n: number): string; }
|
||||
>c.overloaded.bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>c.overloaded : { (s: string): number; (n: number): string; }
|
||||
>c : C
|
||||
>overloaded : { (s: string): number; (n: number): string; }
|
||||
>bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>c : C
|
||||
|
||||
let f16 = c.generic.bind(c); // typeof C.prototype.generic
|
||||
>f16 : <T>(x: T) => T
|
||||
>c.generic.bind(c) : <T>(x: T) => T
|
||||
>c.generic.bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>c.generic : <T>(x: T) => T
|
||||
>c : C
|
||||
>generic : <T>(x: T) => T
|
||||
>bind : { <T>(this: T, thisArg: ThisParameterType<T>): OmitThisParameter<T>; <T, A0, A extends any[], R>(this: (this: T, arg0: A0, ...args: A) => R, thisArg: T, arg0: A0): (...args: A) => R; <T, A0, A1, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1): (...args: A) => R; <T, A0, A1, A2, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2): (...args: A) => R; <T, A0, A1, A2, A3, A extends any[], R>(this: (this: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3, ...args: A) => R, thisArg: T, arg0: A0, arg1: A1, arg2: A2, arg3: A3): (...args: A) => R; <T, AX, R>(this: (this: T, ...args: AX[]) => R, thisArg: T, ...args: AX[]): (...args: AX[]) => R; }
|
||||
>c : C
|
||||
|
||||
let c10 = c.foo.call(c, 10, "hello");
|
||||
>c10 : string
|
||||
>c.foo.call(c, 10, "hello") : string
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user