Commit Graph

32734 Commits

Author SHA1 Message Date
Nathan Shively-Sanders 6a82ae4cbb Add SpreadAssignment to visitors
1. visitNode
2. reduceNode
3. emit

This fixes an emit bug for setters.
2016-11-07 09:04:00 -08:00
Nathan Shively-Sanders a84c7aeea4 Rename SpreadElementExpression -> SpreadAssignment
and SpreadExpression (formerly SpreadElementExpression) -> SpreadElement
2016-11-07 08:36:03 -08:00
Andy Hanson 07630e95e0 Add source maps and declarations to test 2016-11-07 07:14:47 -08:00
Anders Hejlsberg cc9daca38d Accept new baselines 2016-11-06 16:02:32 -08:00
Anders Hejlsberg 2bf4bad0e1 Revert incorrect logic from #11392 2016-11-06 16:00:41 -08:00
Anders Hejlsberg 2564e1cd26 Handle recursion in mapped type display 2016-11-06 12:38:49 -08:00
about-code d9a46e1ae6 Allowing static arguments() and static caller() for target "es6".
Disallow non-function properties `static arguments` and `static caller`, though.
2016-11-06 17:59:38 +01:00
Ron Buckton c6ee25d95b Type checking for async iterables and async generators. 2016-11-05 18:48:33 -07:00
Anders Hejlsberg adfa271e44 Add regression test 2016-11-05 17:36:13 -07:00
Anders Hejlsberg da7f11fe4b Properly instantiate aliasTypeArguments 2016-11-05 17:36:00 -07:00
Anders Hejlsberg 507ab30e9c Handle readonly and optional properties + index signatures 2016-11-05 17:01:47 -07:00
about-code d58b5c807c Fixing wrong line number in tests/baselines/reference/variableDeclarationInStrictMode1.errors.txt
after rebuilding and testing compiler.
2016-11-06 00:39:19 +01:00
Ron Buckton cb853569e4 Relaxed ES2015 restrictions for generator type check 2016-11-05 11:50:54 -07:00
about-code 189dbddb10 Accept baseline tests. Fixing diagnosticMessages.json (merge result not included in prior commit). 2016-11-05 18:42:53 +01:00
about-code 8fa07d695e Merge remote-tracking branch 'upstream/master' 2016-11-05 17:15:51 +01:00
Anders Hejlsberg 4c1e4169bd Accept new baselines 2016-11-05 08:23:42 -07:00
Anders Hejlsberg 61b9da548a Cache generic signature instantiations 2016-11-05 08:20:02 -07:00
Anders Hejlsberg 1c7b397fbb Introduce instantiateCached function 2016-11-05 07:04:56 -07:00
Vladimir Matveev ed4fead087 add missing bind calls to properly set parent on token nodes (#12057) 2016-11-04 21:54:22 -07:00
Anders Hejlsberg 7807ac96f5 Attach symbols to mapped types 2016-11-04 16:47:43 -07:00
Arthur Ozga b7b30aab46 Add straggling Test 2016-11-04 16:36:28 -07:00
Arthur Ozga 1b8486df89 Still re-writing missing member grabber 2016-11-04 16:35:51 -07:00
Arthur Ozga 36c5befae9 Add tests and simplify existing ones 2016-11-04 16:34:10 -07:00
Nathan Shively-Sanders a55ed26d2b Spread any types to any 2016-11-04 16:06:33 -07:00
Anders Hejlsberg ecdb74cee6 Merge branch 'master' into mappedTypes 2016-11-04 14:18:44 -07:00
Anders Hejlsberg fc450a2d2f Introduce MappedType in type checker 2016-11-04 14:17:51 -07:00
Nathan Shively-Sanders 4c365bd76a Move transformFunctionBody to factory
It is shared by es2015 and esNext transformers.

This commit just adds a convertObjectRest flag to be passed on to
flattenDestructuring functions, as well as adding necessary parameters
to use the code outside a transformer.
2016-11-04 13:56:28 -07:00
Nathan Shively-Sanders 4337369ed4 Update improved baselines 2016-11-04 11:07:18 -07:00
Nathan Shively-Sanders cc342d12e7 Move convertForOf to factory for esnext and es2015
Saves a lot of duplicated code
2016-11-04 11:06:56 -07:00
Sheetal Nandi 4a906143c6 Merge pull request #11998 from Microsoft/unusedProperty
Mark property referenced in the destructuring as referenced
2016-11-04 10:42:05 -07:00
Nathan Shively-Sanders 71f3157a35 Address PR comments
1. Remove extra line in __rest shim.
2. Improve __rest vs __assign check for destructuring assignment.
2016-11-04 09:03:03 -07:00
Nathan Shively-Sanders 00ff0e5bb8 Do not add undefined to parameter properties
They are actually properties, so don't get undefined added when they
have an initialiser.

Also update baselines
2016-11-04 08:22:55 -07:00
Ron Buckton defc0537ae Merge pull request #12039 from Microsoft/fix12010
Ensure transformFlags are correct before visiting a node.
2016-11-03 23:38:52 -07:00
Zhengbo Li 1c004bf317 Port #12027, #11980 and #11932 to master (#12037)
* add test for the fix for overwrite emitting error

* cr feedback
2016-11-03 21:13:41 -07:00
Ron Buckton cbec19afd7 Ensure transformFlags are correct before visiting a node. 2016-11-03 17:21:36 -07:00
Ron Buckton fea68278f6 Merge branch 'master' into asyncGenerators 2016-11-03 17:01:59 -07:00
Arthur Ozga 3b0b696517 broken 2016-11-03 16:02:32 -07:00
Nathan Shively-Sanders 286845c6c5 Test adding undefined to default-valued parameters
When --strictNullChecks is on
Also update a baseline that changes now.
2016-11-03 15:35:29 -07:00
Nathan Shively-Sanders 995732fad2 Add undefined to default-valued parameters
When --strictNullChecks is on
2016-11-03 15:35:10 -07:00
Anders Hejlsberg d1a8af5320 Parse '[P in K]' part of mapped type as a type parameter declaration 2016-11-03 14:35:27 -07:00
Nathan Shively-Sanders c9c5f49a24 Improve readability of ES next destructuring emit 2016-11-03 13:36:35 -07:00
Nathan Shively-Sanders 14f8b9990f Update objectRestAssignment test
Missed previously, just got the baselines
2016-11-03 13:33:16 -07:00
Paul van Brenk 40c0cbd7b5 Clean up 2016-11-03 13:28:08 -07:00
Paul van Brenk 2f453ce674 Handle most module cases 2016-11-03 12:48:28 -07:00
Andy Hanson 0b71df5099 Add a .d.ts file to the test to ensure it is excluded from the calculation too 2016-11-03 12:33:03 -07:00
Anders Hejlsberg 702efd559b Merge pull request #12026 from Microsoft/keyofAndConstraints
Fix 'keyof' for constrained type parameters
2016-11-03 11:34:08 -07:00
Anders Hejlsberg 48f2b78125 Merge branch 'master' into keyofAndConstraints 2016-11-03 11:21:13 -07:00
Ron Buckton a2e0b19a94 Emit for full down-level generators 2016-11-03 11:14:12 -07:00
Andy 9705791309 Merge pull request #12021 from Microsoft/tslint_version
Lock tslint version to 4.0.0-dev.0, because 4.0.0-dev.1 complains about unnecessary semicolons following properties
2016-11-03 11:07:25 -07:00
Anders Hejlsberg 6a5de5d00e Fix linting errors 2016-11-03 10:55:58 -07:00