Commit Graph

32750 Commits

Author SHA1 Message Date
Eli Barzilay f017fa04c4 Scan types of yield expressions in classes too
Also, drop the other cases where they were ignored, since they're
forbidden in enums, and the others are fine wrt the comment that was
there.

Fixes #34892
2019-11-22 08:51:00 -05:00
Eli Barzilay 20b246c83a Fix getIntrinsicAttributesTypeFromJsxOpeningLikeElement
Use `getIndexTypeOfType`+`getDeclaredTypeOfSymbol` instead of `getIndexInfoOfSymbol`.

Fixes #34730.
2019-11-22 08:43:24 -05:00
Eli Barzilay cfefe841b7 Allow --inspect=port in gulp runtests
Makes it possible to run two debuggers side-by-side.
2019-11-22 08:42:38 -05:00
Wesley Wigham dc1c45aa9b Fix azure-sdk dockerfile for latest rush 2019-11-21 17:02:57 -08:00
Nathan Shively-Sanders 02348895c9 Add fp-ts to user tests (#35249) 2019-11-21 16:07:55 -08:00
Wesley Wigham 663a42be94 Allow references to globalThis to be made in declaration emit (#35279) 2019-11-21 15:21:35 -08:00
Wesley Wigham cfa367d7f9 Have definite assignment assertions on property signatures mark them as typescript (#35270) 2019-11-21 13:13:46 -08:00
TypeScript Bot 9b78599c63 Update user baselines (#35275) 2019-11-21 13:10:21 -08:00
Anders Hejlsberg 94d4023043 Add inference priority level for conditional types in contravariant positions (#35199)
* Add inference priority level for conditional types in contravariant positions

* Accept new API baselines

* Add regression tests

* Accept new baselines
2019-11-21 13:05:44 -08:00
TypeScript Bot 84c84d8dbc Update user baselines (#35272) 2019-11-21 12:36:55 -08:00
TypeScript Bot 5f1e8cb9b0 Update user baselines (#35271) 2019-11-21 11:34:10 -08:00
Wesley Wigham 614a07c7d5 Fix printing and emit for definite assignment assertions (#35095)
* Fix printing and emit for definite assignment assertions

* Make factories that handle definite assertions internal
2019-11-21 11:20:57 -08:00
Wesley Wigham a6d44aa52e Map stale empty object type in union into fresh empty object type after spread is complete (#34839)
* Map stale empty object type in union into fresh empty object type after spread is complete

* Accept minor baseline diff
2019-11-21 10:57:55 -08:00
TypeScript Bot 0d993ac592 Update user baselines (#35251) 2019-11-20 15:55:13 -08:00
Eli Barzilay 77ec756960 Make getSourceFileToImportFromResolved prefer files in program.getSourceFiles()
Fixes #30550
2019-11-20 18:00:10 -05:00
TypeScript Bot ca4486a065 Update user baselines (#35218) 2019-11-20 14:56:28 -08:00
Sheetal Nandi 0e736a7438 Fix the usage of pattern matching in module resolution for check of hasZeroOrOneAsteriskCharacter (#35209)
* Fix the usage of pattern matching for check of hasZeroOrOneAsteriskCharacter
Fixes #35171

* Fix error message
2019-11-20 10:55:40 -08:00
Kārlis Gaņģis 17f5469a2c Fix crash with Object.defineProperty for imported alias (--allowJs) (#35198)
Fixes #35196
2019-11-20 10:50:47 -08:00
Nathan Shively-Sanders 75301c8e2c DOM update 2019-11-19 (#35207)
* DOM update 2019-11-19

* update baselines

* update more baselines
2019-11-19 15:02:51 -08:00
Andrew Branch 571ca60b08 Add preceding semicolon on await insertion when parentheses are included (#34627)
* Add preceding semicolon on await insertion when parentheses are included

* Just start with precedingToken

* Fix semicolon formatter regression

* Delete test with debatable expected behavior

* Lint after control flow changes
2019-11-19 13:11:42 -08:00
Daniel Rosenwasser b50b9e0fd2 Fix check for get/set recommendation (#34885)
* Added more tests.

* Accepted baselines.

* Work better with any parameter type.

* Accepted baselines.

* Use the actual indexed expression.

* Add tests that exhibit bad stringification.

* Accepted baselines.

* Short-circuit stringification on 'undefined'.

* Accepted baselines.

* Remove space.

* Accepted baselines.
2019-11-19 13:00:24 -08:00
Nathan Shively-Sanders 0bbeab6e61 Revert "Skip costly tests" (#35197)
* Revert "Skip costly tests"

* fix package.json format
2019-11-19 12:59:09 -08:00
Orta af0d5d33b6 Improve positioning of the implement interface codefix (#34928) 2019-11-19 12:13:50 -05:00
Ron Buckton 6c59dc34ac More tests for super.method call chain, improve vary-by (#35013) 2019-11-18 18:03:37 -08:00
Klaus Meinhardt fce728e07f fix emit for delete on optional chain (#35090)
* fix emit for delete on optional chain

* Apply suggestions from code review

Co-Authored-By: Ron Buckton <ron.buckton@microsoft.com>
2019-11-18 16:34:47 -08:00
Anders Hejlsberg 8b83703632 Properly strip readonly from rest argument types (#35169)
* Properly strip readonlyness from rest argument types

* Add tests

* Accept new baselines
2019-11-18 13:11:36 -08:00
Orta e39bdc3606 Adds back the script to request a playrgound build (#35168) 2019-11-18 12:05:54 -05:00
Sheon Han 2511f3438b fix: mardkown link syntax error (#35123) 2019-11-18 10:36:23 -05:00
Anders Hejlsberg 196c0aa078 Fix excess property checking for unions with index signatures (#34927)
* Fix excess property checking for union targets with index signatures

* Accept new baselines

* Remove unused code

* Add tests

* Accept new baselines
2019-11-15 10:59:58 -08:00
Andrew Branch 48fa3a5f18 Update LKG (#35128) 2019-11-15 10:31:30 -08:00
Jack Williams 3bcea0dbba Fix #35060 (#35065)
* Fix 35060

* Refactor and check ro-array to tuple case

* Lint
2019-11-15 10:13:10 -08:00
Klaus Meinhardt 5321dcb09f disallow 'await' and 'yield' in property and enum member initializer (#34892)
* disallow 'await' and 'yield' in property and enum member initializer

* accept baseline changes

* Add a test for #34887

Ensures that this fixes #34887
2019-11-14 17:44:48 -08:00
Klaus Meinhardt 8f40ac06cc optimize transform of optional chaining and nullish coalescing (#34951)
* optimize transform of optional chaining and nullish coalescing

* remove unnecessary condition

* typo

* fix lint

* prevent capturing of super

* swap branches again

* accept new baselines

* avoid temporary objects
2019-11-14 17:34:13 -08:00
Sheetal Nandi aa0cb889da Support dynamic file names with project root path (#35111)
* Support dynamic file names with project root path
Fixes #35094

* Remove unexpected change
2019-11-14 15:37:00 -08:00
Orta ef0cca7d12 Adds 'did you mean' to the CLI args parser (#35063)
* Adds did you mean to the CLI args parser

* Adds test coverage for the did you mean on CLI args

* Adds did you mean to convertOptionsFromJson

* Ensure tsconfig compiler flags also get 'did you mean?'
2019-11-13 20:16:48 -05:00
TypeScript Bot f5bdd4daca Update user baselines (#35075) 2019-11-13 13:13:38 -08:00
Anders Hejlsberg 38db7ae59e Properly analyze switch statement bypass control flow (#35087)
* Properly analyze switch statement bypass control flow

* Add regression test

* Accept new baselines
2019-11-13 09:22:18 -08:00
Wesley Wigham aa39080ac7 Do not allow freshness to move errors out of the current file, ensure json documents are deeply unfreshened and fully widened (#35048) 2019-11-12 13:30:27 -08:00
Nathan Shively-Sanders f3344767dd Fix import type resolution in jsdoc, mark 2 (#35057)
Fake alias resolution only applies when the import type is followed by a
qualified name. Otherwise the alias is sufficiently resolved already.
2019-11-12 12:44:30 -08:00
Klaus Meinhardt 94f85901d7 strip QuestionToken from MethodDeclaration and PropertyDeclaration emit (#34954)
* strip QuestionToken from MethodDeclartion emit

Fixes: #34953

* test property emit
2019-11-12 10:30:46 -08:00
Andrew Casey 5c951635e5 Fix chalk import (#35040) 2019-11-11 11:24:20 -08:00
Anders Hejlsberg 3a5230ab3d Defer switch exhaustiveness checks (#35000)
* Defer switch exhaustiveness checks until they're actually needed

* Add regression test

* Accept new baselines
2019-11-09 07:52:39 -08:00
Wesley Wigham 165b4bc100 More version sanitization 2019-11-07 17:14:16 -08:00
Andrew Branch 53d2b7ed60 Don’t assume importing some JSON means you want everything imported with .js extensions (#34961) 2019-11-07 14:55:54 -08:00
Andrew Branch 4cbace7110 Add "auto" to importModuleSpecifierPreference (#34981)
* Add "auto" to importModuleSpecifierPreference

* Update APIs
2019-11-07 14:55:13 -08:00
Wesley Wigham db43be130d Fix missing semicolon 2019-11-07 14:53:12 -08:00
Wesley Wigham 07d80edb3f Strip more timestamps and versions from docker logs to better handle the more verbose logging from office-ui-fabric 2019-11-07 14:11:33 -08:00
Andrew Branch f2146a627c Fix isInJsxText after JSXOpeningElement with type arguments (#34958)
* Fix `isInJsxText` after JSXOpeningElement with type arguments

* Do the same thing a different way
2019-11-06 15:02:45 -08:00
Orta b9fe84e591 Fix up some of the ignore files, and removing the create language service script (#33684)
* Fix up some of the ignore files, and removing the create script

* Update .dockerignore
2019-11-06 11:11:29 -05:00
Anders Hejlsberg 1c42c1aaa8 Fix control flow analysis in try-catch-finally (#34880)
* Revise creation of control flow graph for try-catch-finally statements

* Add tests

* Accept new baselines
2019-11-05 12:06:25 -08:00