Commit Graph

1450 Commits

Author SHA1 Message Date
Daniel Rosenwasser b5f386eb6e Merge pull request #25311 from Microsoft/betterAlwaysTrueFalseErrors
Even better "always true/false" errors
2018-06-29 14:07:04 -07:00
Mohamed Hegazy c27dace3df Merge pull request #25182 from Kingwl/fix-missing-enum-member
add quick fix for add missing enum member
2018-06-29 10:19:23 -07:00
Daniel Rosenwasser 6f06fd0d46 Use a more direct error. 2018-06-28 16:06:55 -07:00
Daniel Rosenwasser 1f8ad2d318 indicates -> indicate 2018-06-27 17:20:24 -07:00
Daniel Rosenwasser 63a52cd21e Give a better message up-front for incompatible equality errors. 2018-06-26 15:11:41 -07:00
王文璐 a62a54df57 Merge branch 'master' into fix-missing-enum-member 2018-06-26 10:30:09 +08:00
Anders Hejlsberg 70975cd08f Merge pull request #24897 from Microsoft/restTuples
Tuples in rest parameters and spread expressions
2018-06-25 19:26:35 -07:00
王文璐 d5268c81e7 add quick fix for add missing enum member 2018-06-26 10:17:22 +08:00
Andy 806a661be3 Add refactor to convert named to default export and back (#24878)
* Add refactor to convert named to default export and back

* Support ambient module

* Handle declaration kinds that can't be default-exported

* Update API (#24966)
2018-06-25 10:34:24 -07:00
Anders Hejlsberg 28c9f5933a Complete support for rest elements in tuples 2018-06-24 14:32:41 -10:00
Anders Hejlsberg b0d8c6551e Merge branch 'master' into restTuples
# Conflicts:
#	src/compiler/checker.ts
2018-06-22 06:10:50 -10:00
Andy 2b9166b2f9 Don't recommend to install '@types/foo' if that already exists (#24815)
* Don't recommend to install '@types/foo' if that already exists

* Add different extra diagnostic text if the @types package exists

* Update API (#24966)
2018-06-21 10:19:14 -07:00
Anders Hejlsberg 4f99bc19c8 Merge branch 'master' into restTuples
# Conflicts:
#	tests/baselines/reference/APISample_Watch.errors.txt
#	tests/baselines/reference/APISample_WatchWithDefaults.errors.txt
#	tests/baselines/reference/APISample_WatchWithOwnWatchHost.errors.txt
#	tests/baselines/reference/APISample_compile.errors.txt
#	tests/baselines/reference/APISample_jsdoc.errors.txt
#	tests/baselines/reference/APISample_linter.errors.txt
#	tests/baselines/reference/APISample_parseConfig.errors.txt
#	tests/baselines/reference/APISample_transform.errors.txt
#	tests/baselines/reference/APISample_watcher.errors.txt
#	tests/baselines/reference/api/tsserverlibrary.d.ts
#	tests/baselines/reference/api/typescript.d.ts
2018-06-16 07:47:30 -07:00
Ryan Cavanaugh 73844ac565 Accept baseline 2018-06-15 11:10:54 -07:00
Ryan Cavanaugh 066b191982 Collapse core/compiler/parser into parser 2018-06-11 17:07:58 -07:00
Ryan Cavanaugh 336c37662d Projzilla phase 1 2018-06-09 16:48:08 -07:00
Ryan Cavanaugh b107849a3a Improve handling of container projects and issue relative filename messages 2018-06-06 13:47:59 -07:00
Ryan Cavanaugh 291289f8c2 Update messages 2018-06-06 13:03:03 -07:00
Ryan Cavanaugh cf87bd446d Merge branch 'master' into tsbuild 2018-06-05 14:55:51 -07:00
Ryan Cavanaugh 45842a0c34 Merge remote-tracking branch 'weswigham/sourcemap-concatenation-station' into tsbuild 2018-06-05 12:31:32 -07:00
Ron Buckton 666841264c Merge branch 'master' into libReference 2018-06-04 14:38:56 -07:00
Nathan Shively-Sanders 34e68efdae Template tag allows specification of constraints (#24600)
* Parse (and mostly support) template tag constraints

A bunch of tests hit the asserts I added though.

* Messy version is finished. Need to add a few tests

* Refactor to be smaller

* Small refactor + Add one test

* Another test

* Minor cleanup

* Fix error reporting on type parameters on ctors

* Simplify syntax of `@template` tag

This is a breaking change, but in my sample, nobody except webpack used the
erroneous syntax. I need to improve the error message, so
jsdocTemplateTag3 currently fails to remind me of that.

* Better error message for template tag

* Fix fourslash baselines

* Another fourslash update

* Address PR comments

* Simplify getEffectiveTypeParameterDeclarations

Make checkGrammarConstructorTypeParameters do a little more work
2018-06-04 11:42:46 -07:00
Ryan Cavanaugh d21c03ab9d Invalidation + separated downstream builds 2018-05-31 14:38:26 -07:00
Ron Buckton b4e113b94e Merge branch 'master' into libReference 2018-05-31 10:02:08 -07:00
Andy 43bf039a94 Add refactor to convert namespace to named imports and back (#24469)
* Add refactor to convert namespace to named imports and back

* Add tests and comments

* Code review

* Handle shorthand property assignment and re-export

* Don't use forEachFreeIdentifier

* Fix rename after "."
2018-05-30 14:11:53 -07:00
Ryan Cavanaugh f8c4301f14 Add more errors; commandline help for --build; invalid flag combo detection 2018-05-30 10:00:35 -07:00
Anders Hejlsberg e22a9d6fc1 Merge branch 'master' into unknownType 2018-05-30 07:45:10 -07:00
Ron Buckton ec0af20f5a Merge branch 'master' into libReference 2018-05-29 14:13:00 -07:00
Ryan Cavanaugh fe191fec6d Merge branch 'master' into tsbuild 2018-05-29 13:14:12 -07:00
Anders Hejlsberg a83653ed99 Add new diagnostic 2018-05-27 15:43:44 -07:00
Ryan Cavanaugh 8ac795ba01 Correctly skip upstream-blocked projects 2018-05-24 16:21:32 -07:00
Ryan Cavanaugh 8936b030cd Merge branch 'master' into tsbuild 2018-05-24 13:01:58 -07:00
Ryan Cavanaugh fc22b5b146 WIP 2018-05-24 10:59:07 -07:00
kingwl cb2be44d02 fix export class declare with name object targeting es5 (#17494) 2018-05-24 18:16:38 +08:00
Wenlu Wang 4606709672 add code fix convert to mapped object type (#24286)
* add code fix convert to mapped object type

* add support for type literal and improve test

* fix typo

* add support for heritageClauses

* only determine declaration is not class
2018-05-23 14:09:49 -07:00
Ryan Cavanaugh fa07830ca9 Passing tests 2018-05-22 12:53:31 -07:00
Andy 982c8d0af9 Add suggestion diagnostics for unused label and unreachable code (#24261)
* Add suggestion diagnostics for unused label and unreachable code

* Always error on unused left hand side of comma
2018-05-22 07:56:29 -07:00
Ryan Cavanaugh 7e0825a3e7 Clean, etc 2018-05-21 17:47:58 -07:00
Andy 802dc2bb9b fixUnusedIdentifier: If every VariableDeclaration is unused, remove the VariableStatement (#24231) 2018-05-21 15:54:33 -07:00
Daniel Rosenwasser 3563a0576d Use single quotes around 'typeof' in message. 2018-05-18 23:44:38 -07:00
Andy 3eb66da155 Add code fix to remove unused label (#24037)
* Add code fix to remove unused label

* Test with trivia and fix indentation with dedented label
2018-05-18 15:25:24 -07:00
王文璐 5d233054c3 add quick fix for import type missing typeof 2018-05-17 16:35:20 +08:00
Ron Buckton 8548fb835a Merge branch 'master' into libReference 2018-05-11 20:05:26 -07:00
Andy 6ae4d3a516 Add code fix to remove unreachable code (#24028)
* Add code fix to remove unreachable code

* Code review

* Preserve more kinds of statements
2018-05-10 16:44:48 -07:00
Andy 7271ec1240 Add 'move to new file' refactor (#23726)
* Add 'move to new file' refactor

* Code review, and support commonjs

* Compute movedSymbols completely before using, and support `export import`

* Fix assertion error: sort empty change before non-empty change

* Remove extra newline

* Add allowTextChangesInNewFiles preference

* Add the new file to 'files' in tsconfig

* Avoid parameter initializer

* Update API baselines

* Use path relative to tsconfig.json

* Code review

* Fix error where node in tsconfig file was missing a source file
2018-05-10 11:17:04 -07:00
Ron Buckton 698f229bb4 Merge branch 'master' into libReference 2018-05-09 11:41:13 -07:00
Mohamed Hegazy 9ea4d93823 Merge pull request #23957 from paulkoerbitz/16675-better-error-message-for-dynamic-import
Fix #16675: Better error message for dynamic import with ES2015 modules
2018-05-09 09:42:58 -07:00
Paul Koerbitz 89d2baede7 Adress review comments 2018-05-09 10:53:27 +02:00
Andy 5725428f2d fixUnusedIdentifier: Handle destructure with all bindings unused (#23805)
* fixUnusedIdentifier: Handle destructure with all bindings unused

* Add parameters test

* Add test for 'for' loop
2018-05-08 13:33:55 -07:00
Paul Koerbitz ba360cfc4f Make error message for dynamic imports when module is ES2015 more helpful 2018-05-08 07:45:48 +02:00