Sheetal Nandi
d419968c0d
Refresh semantic diagnostics when compiler options affecting semantic diagnostics generation changes
...
Fixes #26195
2018-08-03 16:27:25 -07:00
Sheetal Nandi
8ea95023f1
Make a map for semantic diagnostics from old state
2018-08-01 13:00:26 -07:00
Sheetal Nandi
50b75e7585
Optimize the deletion and calculation of bigger set of semantic diagnostics to be calculated
2018-07-12 13:44:56 -07:00
Sheetal Nandi
585acb1990
Use exported modules through declaration emit to invalidate the semantic diagnostics
...
Fixes #24986
2018-07-11 16:43:02 -07:00
Sheetal Nandi
e88305173d
Fix the issue with createSemanticDiagnosticsBuilderProgram, createEmitAndSemanticDiagnosticsBuilderProgram and createAbstractBuilder not assignable to CreateProgram<T>
...
Fixes #24625
2018-06-04 13:03:57 -07:00
Andy
e53e56cf82
Enable '--strictNullChecks' ( #22088 )
...
* Enable '--strictNullChecks'
* Fix API baselines
* Make sys.getEnvironmentVariable non-nullable
* make properties optional instead of using `| undefined` in thier type
* reportDiagnostics should be required
* Declare firstAccessor as non-nullable
* Make `some` a type guard
* Fix `getEnvironmentVariable` definition in tests
* Pretend transformFlags are always defined
* Fix one more use of sys.getEnvironmentVariable
* `requiredResponse` accepts undefined, remove assertions
* Mark optional properties as optional instead of using `| undefined`
* Mark optional properties as optional instead of using ` | undefined`
* Remove unnecessary null assertions
* Put the bang on the declaration instead of every use
* Make `createMapFromTemplate` require a parameter
* Mark `EmitResult.emittedFiles` and `EmitResult.sourceMaps` as optional
* Plumb through undefined in emitLsit and EmitExpressionList
* `ElementAccessExpression.argumentExpression` can not be `undefined`
* Add overloads for `writeTokenText`
* Make `shouldWriteSeparatingLineTerminator` argument non-nullable
* Make `synthesizedNodeStartsOnNewLine` argument required
* `PropertyAssignment.initializer` cannot be undefined
* Use one `!` at declaration site instead of on every use site
* Capture host in a constant and avoid null assertions
* Remove few more unused assertions
* Update baselines
* Use parameter defaults
* Update baselines
* Fix lint
* Make Symbol#valueDeclaration and Symbol#declarations non-optional to reduce assertions
* Make Node#symbol and Type#symbol non-optional to reduce assertions
* Make `flags` non-nullable to reduce assertions
* Convert some asserts to type guards
* Make `isNonLocalAlias` a type guard
* Add overload for `getSymbolOfNode` for `Declaration`
* Some more `getSymbolOfNode` changes
* Push undefined suppression into `typeToTypeNodeHelper`
* `NodeBuilderContext.tracker` is never `undefined`
* use `Debug.assertDefined`
* Remove unnecessary tag
* Mark `LiteralType.freshType` and `LiteralTupe.regularType` as required
2018-05-22 14:46:57 -07:00
Sheetal Nandi
44066d6c7a
Handle the test case when tsconfig file changes without needing to update the program
...
Fixes #23687
2018-04-27 16:59:50 -07:00
Ryan Cavanaugh
8294259ec2
Remove all reference comments from compiler/
2018-04-11 15:38:26 -07:00
Sheetal Nandi
7329eb1ab1
Make sure config file parsing errors are available through program
...
Fixes #22570 , #21940
2018-03-15 14:58:50 -07:00
Andy
b3edc8f9f4
Apply 'no-unnecessary-type-assertion' lint rule ( #22005 )
...
* Apply 'no-unnecessary-type-assertion' lint rule
* Fix type error
* Fix tsconfig.json
* Add --format back
2018-02-16 18:38:00 -08:00
Andy
28c4871c99
hasSameKeys: Simplify and optimize for identical maps ( #21763 )
2018-02-08 09:45:43 -08:00
Sheetal Nandi
2be231d339
Add createProgram on WatchCompilerHost
2018-01-19 15:52:21 -08:00
Sheetal Nandi
bd43e45075
Move getCurrentDirectory to builder program
2018-01-18 09:19:57 -08:00
Sheetal Nandi
a75badfd11
Rename on WatchBuilderProgram
2017-12-07 19:59:00 -08:00
Sheetal Nandi
8ad9a6254c
Api to get underlying program from builder
2017-12-07 19:45:28 -08:00
Sheetal Nandi
9b54d2e458
Create api to create Watch<BuilderProgram>
2017-12-07 19:22:17 -08:00
Sheetal Nandi
dc62bb9abc
Change builder to BuilderProgram so it is similar to operating on program
2017-12-07 18:58:15 -08:00
Sheetal Nandi
965f40f213
Use builder state in the semantic/emit builder as well
2017-12-07 17:11:36 -08:00
Sheetal Nandi
bb0fc0d2bc
Convert builder state to mutable data, so that later we can create builder Program out of this
2017-12-07 14:15:59 -08:00
Sheetal Nandi
2586bb303c
From builder use the builderState containing references and file infos
2017-12-07 12:39:26 -08:00
Sheetal Nandi
39bf33d841
Few renames
2017-12-07 10:02:02 -08:00
Sheetal Nandi
a21b074055
Update the builder to take options aligning with the WatchCompilerHost
2017-12-06 13:59:53 -08:00
Sheetal Nandi
012f12bcbd
To handle cancellation token, remove changed/affected files from the changeset only after getting the result
2017-11-22 18:24:53 -08:00
Sheetal Nandi
ffa64e8c4f
Set program as affected if emitting/diagnostics for whole program
2017-11-22 11:49:08 -08:00
Sheetal Nandi
e102fee363
Use the results from affected file enumerator apis as Affected File result
2017-11-22 11:49:08 -08:00
Sheetal Nandi
85ce1d0398
Make the builder state as internal and expose builder instead of builder state
2017-11-22 11:49:08 -08:00
Sheetal Nandi
c9a17f325b
Add api to get the dependencies of the file
2017-11-22 11:48:51 -08:00
Sheetal Nandi
7ebf9d9f9d
Lint errors fix
2017-11-22 11:48:50 -08:00
Sheetal Nandi
a06f0c3d9f
Use builder state to emit instead
2017-11-22 11:48:50 -08:00
Andy
592ee00906
Have CompletionEntryDetails source use a relative path ( #19917 )
...
* Have CompletionEntryDetails source use a relative path
* Use getCanonicalFileName from services Instead of creating a new one
2017-11-14 14:26:49 -08:00
Sheetal Nandi
9bea0dbdc2
Actually use cached semantic diagnostics
2017-10-18 15:28:20 -07:00
Sheetal Nandi
7e780c0a1a
Do not cache the semantic diagnostics when compiler options has --out since we would anyways get all fresh diagnostics
2017-10-18 13:49:54 -07:00
Sheetal Nandi
835d7cb910
Simplify emit changed files further
...
Also use source file version as the signature of declaration file instead of computing it from text
2017-10-18 13:34:13 -07:00
Sheetal Nandi
8fbfb5ffc0
Modify api to emit affected files using callback instead of generating in memory output
...
Also marking few apis introduced during watch improvements changes that are suppose to be internal for now
2017-10-18 13:34:13 -07:00
Sheetal Nandi
f9c901ada7
Use get files affected by internally and hence use file paths as input
2017-10-18 13:34:13 -07:00
Sheetal Nandi
142a88a4ae
Update the comment on emit handler method
2017-10-11 10:51:46 -07:00
Sheetal Nandi
9767d77143
Update comment on emit handler functions
2017-10-10 18:41:45 -07:00
Sheetal Nandi
bf4ca30bc3
Let builder find out from imports/typereference directives if file references have changed.
...
This is needed to ensure that the ambient module addition takes effect
Fixes #15632
2017-10-04 18:09:09 -07:00
Andy
efa274f722
When emitting all files, emit the changed file first ( #18930 )
...
* When emitting all files, emit the changed file first
* Export interface
2017-10-04 13:30:37 -07:00
Sheetal Nandi
8ac01d76f5
Separate namespace declarations in builder of intenal and exported interfaces and functions
2017-10-02 17:16:49 -07:00
Sheetal Nandi
7f969e8138
Making APIs as internal so that we can enable them after we have figured out final details
2017-10-02 16:27:26 -07:00
Sheetal Nandi
835153ba50
PR feedback
2017-10-02 12:22:05 -07:00
Sheetal Nandi
68d360585a
PR feedback
2017-09-26 16:21:15 -07:00
Sheetal Nandi
4f7c0e5e1c
Simplify event sent on background project update since its anyways just to update the error list
2017-09-12 18:16:31 -07:00
Sheetal Nandi
fdb104b242
Merge branch 'master' into watchImprovements
2017-09-11 13:49:36 -07:00
Sheetal Nandi
5739b6897a
Do not create map just to store empty reference files. Also update file as changed if file text is same but it had invalidated resolution
2017-09-08 18:10:12 -07:00
Sheetal Nandi
4c79033894
Refactoring to watches and caching of system such that we minimize function expressions
...
Also unified watcher info logging
2017-08-31 09:13:59 -07:00
Sheetal Nandi
3b85f3fbe2
Add tests to verify project changed event sent
2017-08-22 17:19:09 -07:00
Sheetal Nandi
e71123857c
Add api in builder to get changed files and use it to send project changed event
2017-08-22 11:28:10 -07:00
Sheetal Nandi
989508245b
Updating according to feedback from PR
2017-08-14 12:52:29 -07:00