Mohamed Hegazy
f2e30f6693
Allow union and intersection as targets for object spread and rest, and distribute spread&rest over unions
2016-11-29 00:04:20 -08:00
Anders Hejlsberg
5dd4c9ef54
Merge pull request #12528 from Microsoft/mappedTypeInference
...
Type inference for isomorphic mapped types
2016-11-28 13:30:45 -08:00
Anders Hejlsberg
9065b50172
getRegularTypeOfLiteralType before exhaustive switch check
2016-11-28 10:53:25 -08:00
Anders Hejlsberg
3e1b443d77
Deduplicate intersection types before distributing over union types
2016-11-28 09:34:50 -08:00
Anders Hejlsberg
9970606f35
Remove unused code in resolveMappedTypeMembers
2016-11-27 19:58:05 -08:00
Anders Hejlsberg
8ee5f7d64f
Remove unused case in type inference
2016-11-27 19:49:57 -08:00
Anders Hejlsberg
ecd10be177
Reorder type inference cases
2016-11-27 12:48:59 -08:00
Anders Hejlsberg
0a1a3eced4
Merge branch 'master' into mappedTypeInference
...
# Conflicts:
# src/compiler/checker.ts
2016-11-26 18:39:27 -08:00
Anders Hejlsberg
88b7d53978
Merge pull request #12515 from Microsoft/fixMappedTypeInference
...
Include mapped types in type inference infinite recursion check
2016-11-26 18:14:18 -08:00
Anders Hejlsberg
f2c32d251f
Include mapped types in type inference infinite recursion check
2016-11-26 12:17:19 -08:00
Anders Hejlsberg
46ca0ba41e
Fix multiple 'keyof' issues with 'for-in' and 'in' operator
2016-11-26 09:58:44 -08:00
Anders Hejlsberg
36ad772c55
Type inference for isomorphic mapped types
2016-11-23 20:07:53 -08:00
Anders Hejlsberg
cdda5dfd61
keyof T is a literal contextual type
2016-11-23 18:22:57 -08:00
Anders Hejlsberg
e128add54e
Merge pull request #12447 from Microsoft/mappedTypesAndUnions
...
Isomorphic mapped types and unions
2016-11-23 17:36:44 -08:00
Daniel Rosenwasser
4701eb70e2
Merge pull request #12357 from mylesmegyesi/12075-incorrectErrorMessageForUseOfTypeAsNamespace
...
Fixes error message when Type is used as a Namespace
2016-11-23 11:08:38 -05:00
Anders Hejlsberg
864e1797d9
Merge pull request #12396 from Microsoft/getTypeOfExpression
...
Introduce 'getTypeOfExpression' function
2016-11-22 15:33:37 -08:00
Anders Hejlsberg
d7dd0289d5
Distribute isomorphic mapped types over union types
2016-11-22 14:27:39 -08:00
Ryan Cavanaugh
86583d495c
Merge pull request #12441 from RyanCavanaugh/jsDocAugments
...
Support JSDoc @augments tag
2016-11-22 11:23:45 -08:00
Ryan Cavanaugh
6a5682c4a3
Support JSDoc @augments tag
...
Fixes #12428
2016-11-22 10:52:47 -08:00
Anders Hejlsberg
77c0540433
Merge pull request #12425 from Microsoft/keyofOnlyStrings
...
Change 'keyof T' to always be string-like
2016-11-21 15:51:00 -08:00
Anders Hejlsberg
1710df5f28
Type of for-in variable is keyof T when object type is a type parameter
2016-11-21 12:56:32 -08:00
Anders Hejlsberg
76ceab97dd
Make keyof T a string-like type
2016-11-21 11:41:51 -08:00
Nathan Shively-Sanders
409253145e
Merge pull request #12335 from Microsoft/getJSDoc-cleanup
...
getJSDocs cleanup
2016-11-21 11:30:27 -08:00
Anders Hejlsberg
998246af9c
Merge pull request #12389 from Microsoft/keyofRelations
...
Minor fixes for 'keyof T' and indexed acces types
2016-11-20 15:54:41 -08:00
Anders Hejlsberg
4ed3225c06
Add optimized getTypeOfExpression function
2016-11-20 08:13:39 -08:00
Anders Hejlsberg
dcd225a892
Fix comparable relation for keyof T
...
Treat keyof T as string | number for purposes of indexing
Allow indexed access types with for-in and in operator
2016-11-19 09:03:23 -08:00
Nathan Shively-Sanders
71b28a024a
Merge pull request #12310 from Microsoft/check-object-rest-destructuring-assignment
...
Check object rest destructuring assignment
2016-11-18 16:01:25 -08:00
Nathan Shively-Sanders
b514d7c91c
Merge pull request #12362 from Microsoft/disable-evolving-types-with-implicit-any
...
Disable evolving types with implicit any
2016-11-18 15:39:02 -08:00
Nathan Shively-Sanders
ab84cd0647
Improve readability of types and names
2016-11-18 15:03:40 -08:00
Nathan Shively-Sanders
7750fe1a7c
Always enable evolving types in Javascript files
2016-11-18 14:13:56 -08:00
Nathan Shively-Sanders
8674d92bdb
Disable evolving types with implicit any
...
That is, without --noImplicitAny
2016-11-18 13:51:44 -08:00
Anders Hejlsberg
2376e30410
Support apparent types for T[K] indexed access types
2016-11-18 13:30:56 -08:00
Myles Megyesi
d8b0f239f1
Fixes error message when Type is used as a Namespace
...
Fixes #12075
2016-11-18 11:38:24 -06:00
Anders Hejlsberg
63387bb5e0
Error on circular constraints in mapped types
2016-11-18 06:13:04 -08:00
Anders Hejlsberg
2646828198
Type relations for generic mapped types
2016-11-17 20:18:00 -08:00
Nathan Shively-Sanders
ddffe209f9
Clean up getJSDocParameterTag
...
And delete its near-duplicate which was much less correct. The callers
that had to switch are slightly more complex and more correct now.
2016-11-17 14:26:38 -08:00
Nathan Shively-Sanders
5a05b94fb5
Clean up getJSDocs
...
1. Get rid of parent check.
2. Use a couple of nested functions, one of them a recursive worker.
2016-11-17 13:27:57 -08:00
Nathan Shively-Sanders
ad9ad8f948
Clean up getJSDocTypeForVariableLikeDeclarationFromJSDocComment
...
Yeah, that name is way too long.
2016-11-17 11:08:11 -08:00
Paul van Brenk
52ec508e27
Code fix for missing imports ( #11768 )
...
* Add codefix for missing imports + tests
* Re-order and cleanup
* refactor
* make tests pass
* Make import specifier for new imports more comprehensive
* Fix existing import cases
* refactor
* Fix multiple import statement case
* add multiple code fixes and code action filtering and polishing
* not using the generic verify method for import fixes.
* Correct insert position for new imports
* improve the code action filtering logic
* Fix line ending issue
* cache where we can
2016-11-16 16:01:16 -08:00
Nathan Shively-Sanders
5dbe5f4fbd
Widen literal types of parameter properties
2016-11-16 15:24:42 -08:00
Nathan Shively-Sanders
074014e039
Check assignability: rest destructuring assignment
2016-11-16 13:41:25 -08:00
Ron Buckton
3a95f9244b
Merge pull request #11874 from Microsoft/emitHelper
...
Move emit helpers into related transformers
2016-11-16 10:37:35 -08:00
Anders Hejlsberg
a5d9e9624d
Merge pull request #12301 from Microsoft/recursiveMappedTypes
...
Fix recursive mapped types
2016-11-16 10:23:14 -08:00
Anders Hejlsberg
c5ab4735ac
Resolve upfront so recursive mapped types appear empty
2016-11-16 06:48:51 -08:00
Ron Buckton
ec95f4f0f7
Merge branch 'streamlineDestructuring' into emitHelper
2016-11-15 18:13:52 -08:00
Ron Buckton
3a67174314
Merge branch 'master' into streamlineDestructuring
2016-11-15 18:10:02 -08:00
Ron Buckton
346d488c62
Merge branch 'master' into emitHelper
2016-11-15 17:13:57 -08:00
Ron Buckton
0dd96f52e8
Merge branch 'master' into streamlineDestructuring
2016-11-15 13:38:56 -08:00
Anders Hejlsberg
73ada7a78d
Merge pull request #12251 from Microsoft/fixTypePredicateStructuralMatch
...
Fix type predicates with structurally identical types
2016-11-15 13:20:35 -08:00
Anders Hejlsberg
0ba23483e8
Merge pull request #12276 from Microsoft/libMappedTypes
...
Predefined mapped types in lib.d.ts
2016-11-15 13:19:58 -08:00