TypeScript/tests/cases/conformance/expressions
Eli Barzilay 3151e2a365 Make hasCorrectArity handle tuples properly
This completes the work that started in PR #33069, and fixes #32835.

There are probably two additional related changes that are needed to
make this more complete:

* Fix the code that composes the error message (see the first two
  `FIXME`s in `callWithSpread3.ts`).

* Fix the code that checks the argument types (second two `FIXME`s).

* There is also an error in `genericRestParameters1.ts` which changed
  but should not be an error in the first place.  Added a `FIXME` there
  too.  (Probably will work if the previous iterm is done.)

In addition, `getEffectiveCallArguments` munges the arguments in case of
a spread in the last argument which might be better to avoid.  (I think
that there are cases where it wouldn't work anyway, such as a spread of
an array followed by a spread of an empty array.)
2020-06-04 23:46:56 -04:00
..
arrayLiterals Add tests 2019-06-17 16:18:13 -10:00
asOperator Emit parens around type-asserted binary operators 2016-07-15 15:56:22 -07:00
assignmentOperator Go back to the old narrowing algorithm (pre #26143) and avoid #26130 by 2018-08-17 21:35:03 -04:00
binaryOperators fix(36055): forbid union type with invalid types in the 'in' operator (#37786) 2020-05-06 11:41:50 -07:00
commaOperator Add suggestion diagnostics for unused label and unreachable code (#24261) 2018-05-22 07:56:29 -07:00
conditonalOperator Tests for Conditional operator can generate union type 2014-11-04 13:18:43 -08:00
contextualTyping Fix incorrect noImplicitAny error on contextual union function signature 2019-06-24 17:37:14 -07:00
elementAccess Test:string enum in element access 2017-08-24 14:06:21 -07:00
functionCalls Make hasCorrectArity handle tuples properly 2020-06-04 23:46:56 -04:00
functions Add tests 2017-01-07 15:16:26 -08:00
identifiers Add snapshot of compiler sources 2014-07-12 17:30:19 -07:00
literals Add snapshot of compiler sources 2014-07-12 17:30:19 -07:00
newOperator When --noImplicitAny is enabled, don't report errors suggesting that a 'void' function can be 'new'ed (#26579) 2018-08-21 10:02:02 -07:00
nullishCoalescingOperator Fix temp variable scoping in async generators (#38121) 2020-04-24 12:10:29 -07:00
objectLiterals Add tests 2017-10-26 14:56:54 -07:00
operators Unpatch vfs resolver and default lib rename 2018-05-03 14:18:50 -07:00
optionalChaining Fix temp vars referenced in parameter (#38130) 2020-04-23 20:45:39 -07:00
propertyAccess Add tests 2019-06-06 13:33:36 -07:00
superCalls Add snapshot of compiler sources 2014-07-12 17:30:19 -07:00
superPropertyAccess Instantiate this-type in super property access 2016-05-24 13:07:34 -07:00
thisKeyword Add globalThis (#29332) 2019-02-27 14:14:34 -08:00
typeAssertions allow const-assertion on aliased enum symbol (#32110) 2019-06-26 14:42:06 -07:00
typeGuards Make anyArray.filter(Boolean) return any[], not unknown[] (#31515) 2019-05-22 09:45:41 -07:00
unaryOperators Indexed-assignment readonly err is not unknownType 2017-08-16 10:06:01 -07:00
valuesAndReferences Add snapshot of compiler sources 2014-07-12 17:30:19 -07:00