Commit Graph

273 Commits

Author SHA1 Message Date
Andy 36dfd775b3 Parse an object literal property as shorthand unless followed by '(' or ':' (#28121) 2018-10-26 15:00:31 -07:00
Wesley Wigham 05716a74a5 Add support for configuration inheritance via packages (#27348)
* Add support for configuration inheritance via packages

* Fix lint

* Propagate trace into config parse hosts
2018-10-25 10:19:57 -07:00
Andy eadf44d073 Add generateTypesForModule to public API (#28069)
* Add generateTypesForModule to public API

* Avoid parameter initializer and update baselines
2018-10-23 16:10:26 -07:00
Daniel Rosenwasser 68ce68da79 Merge pull request #27964 from Igorbek/issue27854
Fix bug in reduceEachChild for tagged template expressions
2018-10-22 15:49:54 -07:00
Andy 72244c5b03 Support 'isSourceFileFromExternalLibrary' for source files from '/// <reference types="" />'' (#28004)
* Support 'isSourceFileFromExternalLibrary' for source files from '/// <reference types="" />''

* Calculate `isExternalLibraryImport` at the end

* Calculate isExternalLibraryImport with symlink path
2018-10-19 18:00:45 -07:00
Sheetal Nandi ad5599434e Merge pull request #27974 from Microsoft/errorUpdateWithChangeInTransitiveDeclarationFile
Use reference map from declaration file as exported map to handle deep import semantic diagnostics invalidation
2018-10-19 17:32:32 -07:00
Sheetal Nandi d352b8c2c7 Use reference map from declaration file as exported map to handle deep import semantic diagnostics invalidation
Fixes #27973
2018-10-18 12:04:14 -07:00
Igor Oleinikov b2cbbbd1d3 Fix bug in reduceEachChild (fixes #27854)
- add reducing of type arguments in tagged template expression
2018-10-18 01:34:04 -07:00
Igor Oleinikov b1fbff8b98 Add broken test for issue #27854 2018-10-18 00:31:09 -07:00
Sheetal Nandi bc72577ce3 Merge branch 'master' into transitiveReferences 2018-10-16 14:56:07 -07:00
Andy eb2297df02 Fix compile errors in tsbuildWatchMode.ts (#27870)
* Fix compile errors in tsbuildWatchMode.ts

* Remove TODO comments

* new LKG

* Add tslint disables
2018-10-16 12:28:14 -07:00
Sheetal Nandi b69622a114 Merge branch 'master' into transitiveReferences 2018-10-16 10:41:17 -07:00
Andy 0f4a615bcb Fix isSourceFileFromExternalLibrary for file with redirect (#27917)
* Fix isSourceFileFromExternalLibrary for file with redirect

* Alternate fix

* Use currentNodeModulesDepth > 0
2018-10-16 09:01:25 -07:00
Andy 54a5be1860 At '.' in object literal, don't close the object (#27850)
* At '.' in object literal, don't close the object

* Include diagnostics test
2018-10-12 08:49:04 -07:00
Nathan Shively-Sanders ec0e8cbe2b noImplicitAny as suggestion (#27693)
* noImplicitAny as suggestion

Note that not all noImplicitAny errors turn into suggestions. In
particular,

1. reportErrorsFromWidening does not, because it doesn't log an error
that infer-from-usage fixes, and fixing it would require
otherwise-unnecessary code.
2. auto types do not have implicit any suggestions, because that would
require running control flow in noImplicitAny mode.

* Rename reportImplicitAny+forbid it for non-checkJS

In JS, you only get implicit any errors/suggestions with checkJS or
ts-check turned on.

* Update baselines

* Use isCheckJsEnabledForFile

* Remove noImplicitAny parameter since it's in scope already
2018-10-11 16:15:38 -07:00
Sheetal Nandi 92f3f1cde0 Allow files to be included by *.json pattern in include of tsconfig
Fixes #25636
2018-10-11 14:45:27 -07:00
Sheetal Nandi 578f8db7d9 Add test cases for transitive reference with different module resolution 2018-10-11 12:26:19 -07:00
Sheetal Nandi ae1bd8bc33 Merge branch 'master' into transitiveReferences 2018-10-11 11:33:23 -07:00
Sheetal Nandi 0d91838593 Do not generate jsFile path if its emitOnlyDeclarations is set
Fixes #27009
2018-10-11 10:14:59 -07:00
Sheetal Nandi ba0f5581f6 Remove any existing errors in case of successful build in tsbuild watch mode
Fixes #27685
2018-10-10 12:52:34 -07:00
Sheetal Nandi 07966dcb12 Merge pull request #27643 from Microsoft/simpleTypeMap
Converted legacySafelist to map to avoid using array prototype methods accidently to match with filename
2018-10-09 14:11:10 -07:00
Sheetal Nandi 88f79de9f4 Merge branch 'master' into transitiveReferences 2018-10-09 14:03:58 -07:00
Sheetal Nandi 51ff0d32da Merge pull request #27625 from Microsoft/fileAddedWithAmbientModule
Use ambient modules as references to keep track of reporting and usage of modules correctly
2018-10-09 13:43:12 -07:00
Sheetal Nandi b4b29ab1e1 Converted legacySafelist to map to avoid using array prototype methods accidently to match with filename
Eg. constructor.js was adding constructor function to aquisition.include which
resulted in the mismatch between typing installer's typeAquisition (which was passed as JSON string and parsed back to null) and one in project
That meant we kept on queuing the new typing installation request.
Fixes #27435
2018-10-09 13:21:43 -07:00
Andy 1a5e66995a Don't crash if spawnSync result's stderr is null (#27616) 2018-10-09 09:42:43 -07:00
Sheetal Nandi 03a3978d65 Use ambient modules as references to keep track of reporting and usage of modules correctly
Fixes #27585
2018-10-08 15:56:39 -07:00
Sheetal Nandi a6a27e9de9 Merge pull request #27577 from Microsoft/projectLoadEvent
Send event for ProjectLoadStart and ProjectLoadFinish
2018-10-08 12:54:15 -07:00
Sheetal Nandi 37e25c8873 Send even for ProjectLoadStart and ProjectLoadFinish
Fixes #27206
2018-10-05 15:09:33 -07:00
Benjamin Lichtman 2ebd986d99 Always await expression of promise type in return position 2018-10-05 09:59:22 -07:00
Sheetal Nandi dd343149a2 Add tests for project updates with tsserver 2018-10-04 15:04:13 -07:00
Sheetal Nandi 2fb11d8530 Test transitive references in folders side by side so that later we can add tsserver tests as well 2018-10-04 15:04:12 -07:00
Sheetal Nandi 3e67cf43b0 Verify errors on transitively referenced files 2018-10-04 15:04:12 -07:00
Sheetal Nandi 94df5167b0 Handle resolution caching when referenced tsconfig changes 2018-10-04 15:04:12 -07:00
Sheetal Nandi d4e4b43239 Verify that own config change in module resolution gets reflected 2018-10-04 15:04:11 -07:00
Sheetal Nandi 4d413a6a55 Fix the fileByName cache when program is used completely which breaks the getSourceFile not return redirected file by its name 2018-10-04 15:04:11 -07:00
Sheetal Nandi 6923f2cdb0 Handle caching of module resolution depending on project references 2018-10-04 15:04:11 -07:00
Sheetal Nandi 0ac96580d5 Resolve project references transitively 2018-10-04 15:04:10 -07:00
Andy 62306bc3f9 Fix git submodule update syntax (#27549) 2018-10-04 09:03:20 -07:00
Nathan Shively-Sanders 9aeb6e2ac4 Also --init git submodules when running user tests (#27508) 2018-10-03 06:31:26 -07:00
Benjamin Lichtman f356cd6c89 Insert async keyword as last modifier (#27491) 2018-10-01 17:43:17 -07:00
Sheetal Nandi 29dd67ec40 Merge pull request #27443 from Microsoft/errorMessageLogger
Default logger for projectService has assert on exceptions being logged in tsserver
2018-10-01 15:04:03 -07:00
Sheetal Nandi d2647a1dda Merge pull request #27483 from Microsoft/redirects
Fix issue of program not being reused when host implements getSourceFileByPath
2018-10-01 12:46:59 -07:00
Sheetal Nandi dd3277c219 PR feedback 2018-10-01 12:12:22 -07:00
Sheetal Nandi bc23037e14 Merge pull request #27438 from Microsoft/failedLookupNotMatchingPath
Handle the case of failed lookup location being not normalized in resolutionCache to watch the path
2018-10-01 11:57:34 -07:00
Sheetal Nandi c197bae990 Add tests for failing redirect reuse of program when host implements getSourceFileByPath
Test for #27207
2018-10-01 11:51:30 -07:00
Sheetal Nandi 6549969d2c Default logger for projectService has assert on exceptions being logged in tsserver 2018-09-28 15:47:34 -07:00
Sheetal Nandi 552777d70e When there is parse error do not verify actual errors 2018-09-28 15:28:44 -07:00
Sheetal Nandi ee04b8c7f3 Handle the case of failed lookup location being not normalized.
Also fixed issue where type defs with relative name didnt resolve when directoryExists is present on the host
Fixes #27405
2018-09-28 14:40:34 -07:00
Sheetal Nandi 0245c2d35e Only copy non error values in array when converting the json
Fixes #27432
2018-09-28 13:49:00 -07:00
Dhruv Rajvanshi bde81deed2 Issue #27301: Fixed crash when converting function to async (#27396) 2018-09-27 18:56:37 -07:00