Commit graph

753 commits

Author SHA1 Message Date
Nathan Shively-Sanders 738713b146 Improve error reporting
1. Fix bug in error reporting in compareSignaturesRelated.
2. When the this-argument is a union type, allow assignability when the
method's signature is assignable to *any* member of the union.
2016-02-08 14:01:51 -08:00
Nathan Shively-Sanders 2f74da112d Add specific error messages for out-of-place this
Also remove lint in checker.
2016-02-04 16:01:10 -08:00
Nathan Shively-Sanders 8c87da523b First round of review comments addressed.
Only major thing is a bug fix in
`isContextSensitiveFunctionLikeDeclaration`, and turning on context
sensitivity to `this` even with `--strictThis` off.
2016-02-04 15:43:43 -08:00
Nathan Shively-Sanders 8032b06f33 Merge branch 'master' into this-function-types 2016-02-02 16:16:46 -08:00
Daniel Rosenwasser 3dae2534f3 Merge pull request #6278 from Microsoft/theyreNotTHATSpecial
Remove most special treatment of specialized signatures.
2016-02-02 12:45:30 -08:00
Daniel Rosenwasser 0855933757 Merge pull request #6587 from nojvek/master
pretty output for jsx and createElement emits to children array
2016-02-01 21:38:15 -08:00
Daniel Rosenwasser dd0a2e0340 Added tests. 2016-02-01 14:17:29 -08:00
Nathan Shively-Sanders 04e7d81105 Add tests and baselines for this-function types. 2016-01-29 14:49:52 -08:00
Daniel Rosenwasser ad9bff88fa Merge branch 'master' into theyreNotTHATSpecial 2016-01-29 14:47:23 -08:00
Ron Buckton 4835e43a8f Merge branch 'master' into fixDecoratedClassName 2016-01-28 17:59:04 -08:00
Kanchalai Tanglertsampan bf854a784f Merge branch 'master' into fix4211 2016-01-28 14:33:50 -08:00
Ron Buckton 1bb96555da Creates a class body scoped alias to the class to avoid class name double binding.
Fixes #5386.
2016-01-27 16:13:51 -08:00
Daniel Rosenwasser 5e05c75e93 Merge branch 'master' into theyreNotTHATSpecial 2016-01-27 11:53:42 -08:00
Anders Hejlsberg 98603f9f49 Merge pull request #6532 from Microsoft/readonlyMembers
Readonly properties and index signatures
2016-01-27 10:50:26 -08:00
Kanchalai Tanglertsampan e910e7151b Merge branch 'master' into fix4211 2016-01-27 10:36:08 -08:00
Noj Vek a116b4c996 pretty output for react jsx 2016-01-26 22:59:34 -08:00
Kanchalai Tanglertsampan bc2599083c Merge branch 'master' into fix4867_transpiling 2016-01-26 15:37:49 -08:00
Anders Hejlsberg 77d174a314 Adding tests 2016-01-25 11:46:23 -08:00
Anders Hejlsberg ea4e3afd98 Fix tests 2016-01-24 13:44:22 -08:00
Yui T a1acf8f0f3 Merge branch 'master' into fix4867_transpiling 2016-01-21 16:19:25 -08:00
Daniel Rosenwasser 59a1afaac6 Merge branch 'master' into theyreNotTHATSpecial
Conflicts:
	src/compiler/checker.ts
2016-01-19 16:52:46 -08:00
Ron Buckton 5943f043ea Merge branch 'master' into alternateFixSuperInAsyncMethod 2016-01-15 12:51:30 -08:00
Daniel Rosenwasser 403a93d21f Merge pull request #6330 from weswigham/restorative-narrowing
Fix #6277
2016-01-14 16:07:59 -08:00
Nathan Shively-Sanders 911d07a81b Merge pull request #5992 from Microsoft/allow-type-predicates-as-return-types-only
Allow type predicates as return types only
2016-01-13 09:55:40 -08:00
Ryan Cavanaugh 5f024a3c9f Merge pull request #6358 from RyanCavanaugh/fix6349
Change logic in identifying JSX React SFCs
2016-01-12 15:40:52 -08:00
Kanchalai Tanglertsampan 62256bd3c6 Merge branch 'master' into fix4867_transpiling 2016-01-10 18:04:15 -08:00
Yui T c4ce6b85e0 Merge branch 'master' into fix4211 2016-01-10 06:16:02 -08:00
Daniel Rosenwasser ae9a12be93 Merge branch 'master' into theyreNotTHATSpecial 2016-01-08 12:24:13 -05:00
Anders Hejlsberg 1798024f4f Updating tests 2016-01-06 16:13:02 -08:00
Anders Hejlsberg dbb4544d61 Adding new tests 2016-01-06 10:52:54 -08:00
Ryan Cavanaugh aed73bd139 Merge pull request #6291 from RyanCavanaugh/fix6280
Issue correct errors for missing JSX closing tags
2016-01-05 10:23:49 -08:00
Ryan Cavanaugh 53106cb5ed Change logic in identifying SFCs
Our logic for detecting SFC vs Element Class had a few issues:
 * Object Type flag is not actually useful
 * Parameter arity isn't actually relevant
 * The check for Element Class should take priority

Fixes #6349 and #6353
2016-01-04 23:00:22 -08:00
Daniel Rosenwasser 5323fa6783 Added tests for LHS expressions. 2016-01-04 23:00:45 -05:00
Daniel Rosenwasser 06bff434cc Added 'noImplicitAny' to tests. 2016-01-04 22:48:53 -05:00
Daniel Rosenwasser 24a108936f Added tests. 2016-01-04 22:39:31 -05:00
Daniel Rosenwasser 2cb7ab9692 Merge pull request #6232 from Microsoft/contextuallyTypeJsxStringLiteralAttributes
Contextually type JSX string literal attributes
2016-01-04 14:50:09 -05:00
Ryan Cavanaugh 0debd2b6cd Merge pull request #6290 from RyanCavanaugh/fix5865
Tag 'react' import as used if it exists when targeting --jsx preserve
2016-01-04 07:47:01 -08:00
Wesley Wigham 7bb2ee56d0 Fix #6277 - stop looking for any specifically, and use isTypeSubtypeOf like the old code 2016-01-03 07:43:30 -05:00
Ryan Cavanaugh 7aa8ba6ba7 Add test for non-used React import 2016-01-01 09:24:07 -08:00
Ryan Cavanaugh 2c4856ae71 Issue correct errors for missing JSX closing tags
Fixes #6280
2015-12-29 16:00:15 -08:00
Ryan Cavanaugh 7b36432cf0 Add test to verify no error when 'React' is not in scope 2015-12-29 14:57:22 -08:00
Ryan Cavanaugh e12855bca0 Escape quotes when they appear as HTML entities in JSX text
Fixes #6241
2015-12-29 12:39:27 -08:00
Daniel Rosenwasser d9d5e3a283 Added test from #6278. 2015-12-28 16:18:50 -05:00
Daniel Rosenwasser 5f9983a698 Updated tests. 2015-12-28 15:59:29 -05:00
Daniel Rosenwasser 0da676d24c Added tests. 2015-12-28 15:59:17 -05:00
Daniel Rosenwasser 64c96323aa Added test. 2015-12-23 16:50:24 -08:00
Nathan Shively-Sanders 7882fd39e7 Merge branch 'master' into allow-type-predicates-as-return-types-only 2015-12-22 11:25:45 -08:00
Yui T 677e080dad Add tests 2015-12-21 16:23:51 -08:00
Daniel Rosenwasser 73de79c68c Added positive test case suggested in #6129. 2015-12-21 13:42:24 -08:00
Daniel Rosenwasser ee50adbc85 Merge pull request #6129 from pimterry/decorator-overload-msg
Improve decorator on overload error message
2015-12-21 13:30:46 -08:00