==== tests/cases/compiler/genericCallWithConstructorTypedArguments5.ts (4 errors) ====
    // Generic call with parameter of object type with member of function type of n args passed object whose associated member is call signature with n+1 args
    
    function foo<T, U>(arg: { cb: new(t: T) => U }) {
        return new arg.cb(null);
    }
    
    var arg: { cb: new<T>(x: T) => string };
    var r = foo(arg); // {}
    // more args not allowed
    var arg2: { cb: new <T>(x: T, y: T) => string };
    var r2 = foo(arg2); // error
             ~~~
!!! genericCallWithConstructorTypedArguments5.ts(11,10): error TS2082: Supplied parameters do not match any signature of call target:
!!! 	Types of property 'cb' of types '{ cb: new<T>(x: T, y: T) => string; }' and '{ cb: new(t: {}) => {}; }' are incompatible:
!!! 		Construct signatures of types 'new<T>(x: T, y: T) => string' and 'new(t: {}) => {}' are incompatible:
!!! 			Call signature expects 1 or fewer parameters.
             ~~~
!!! genericCallWithConstructorTypedArguments5.ts(11,10): error TS2087: Could not select overload for 'call' expression.
    var arg3: { cb: new (x: string, y: number) => string };
    var r3 = foo(arg3); // error
             ~~~
!!! genericCallWithConstructorTypedArguments5.ts(13,10): error TS2082: Supplied parameters do not match any signature of call target:
!!! 	Types of property 'cb' of types '{ cb: new(x: string, y: number) => string; }' and '{ cb: new(t: {}) => {}; }' are incompatible:
!!! 		Construct signatures of types 'new(x: string, y: number) => string' and 'new(t: {}) => {}' are incompatible:
!!! 			Call signature expects 1 or fewer parameters.
             ~~~
!!! genericCallWithConstructorTypedArguments5.ts(13,10): error TS2087: Could not select overload for 'call' expression.
    
    function foo2<T, U>(arg: { cb: new(t: T, t2: T) => U }) {
        return new arg.cb(null, null);
    }
    
    // fewer args ok
    var r4 = foo(arg); // {}
    var arg4: { cb: new (x: string) => string };
    var r6 = foo(arg4); // string
    var arg5: { cb: new () => string };
    var r7 = foo(arg5); // string
    