Commit Graph

5163 Commits

Author SHA1 Message Date
Andrew Branch
a890275463 Merge pull request #31912 from andrewbranch/bug/31657
Fix smartSelection returning extra span inside string quotes when cursor is outside them
2019-07-01 11:53:24 -07:00
Titian Cernicova-Dragomir
e4bca9649a Improved error spans for call errors:
1. When calling a non-callable expression the error span is on the call target not on the whole call
2. When calling a method, the error for overload resolution now includes the arguments (this was previously regressed by #31414)
2019-06-28 23:53:47 +03:00
Titian Cernicova-Dragomir
768318b30c Improved error message for calling/constructing types 2019-06-28 23:23:16 +03:00
Orta
a50a5d309c Merge pull request #32088 from orta/fix-32068
Handle making sure that two less thans are never converted into >>
2019-06-26 14:10:02 -07:00
Orta Therox
897fb3a2a6 Handle making sure that two less thans are never converted into >> 2019-06-25 15:16:15 -07:00
Orta Therox
444c3059f6 Handle feeedback 2019-06-25 09:41:26 -07:00
Orta
0a272e04ef Update src/services/formatting/README.md
Co-Authored-By: Andrew Branch <andrewbranch@users.noreply.github.com>
2019-06-24 17:08:34 -07:00
Orta
3f9395be39 Update src/services/formatting/README.md
Co-Authored-By: Andrew Branch <andrewbranch@users.noreply.github.com>
2019-06-24 17:08:28 -07:00
Orta Therox
ba4aad79dc Adds some docs for how a formatter works 2019-06-24 15:42:56 -07:00
Wesley Wigham
1cbace6eee Remove secondary reference lookup implementation (#32016)
* Remove secondary reference lookup implementation

* Remove TODO
2019-06-21 13:26:29 -07:00
Sheetal Nandi
7ed3896a0a Merge pull request #31587 from microsoft/definitionSpan
Include declarationSpan as relevant declaration span when defintion or other places are declaration name
2019-06-18 14:07:15 -07:00
Josh Goldberg
ca00b3248b Added --noImplicitThis code fix for functions used as object properties (#31138)
* Added --noImplicitThis code fix for functions used as object properties

Before trying out all the various possibilities for where these functions could be used, I figured I'd start out with a relatively simple use case to verify this is the right approach. Is it? 😄

Starts on #28964.

* Fixed function expression names; included new baselines

* Got JSDocs to work, hooray!

* Added test for 'any' case of no function uses

* Refactored for inferFunctionReferencesFromUsage

* Fixed inference bug: undefined references cause parameters to default

* Removed dead code comments
2019-06-17 19:00:15 -07:00
Andrew Branch
54f5f2baf2 Fix smartSelection returning extra span inside string quotes when cursor is outside them 2019-06-14 15:50:09 -07:00
Sheetal Nandi
73bf2684ac Rename to use contextSpan 2019-06-13 12:41:21 -07:00
Sheetal Nandi
da2aa9781e Revert to using spread instead of mutating value later 2019-06-12 15:25:16 -07:00
Benjamin Lichtman
0628adc056 Merge pull request #31865 from amcasey/FunctionHintSpan
Correct outline hint spans for functions
2019-06-12 10:13:21 -07:00
Andrew Casey
65881602b6 Correct outline hint spans for functions 2019-06-11 16:58:08 -07:00
Daniel Rosenwasser
79aff027f3 Merge pull request #31290 from a-tarasyuk/bug/29880
29880 - No completions for computed string properties
2019-06-10 13:45:58 -07:00
Sheetal Nandi
a84ed93f72 Merge branch 'master' into definitionSpan 2019-06-06 14:13:09 -07:00
Sheetal Nandi
a67b375d0e Handle module specifiers 2019-06-06 13:39:04 -07:00
Sheetal Nandi
a120c59015 Handle Lable 2019-06-06 12:04:48 -07:00
Sheetal Nandi
768c9ed8d7 Handle jsx Opening, Closing and Self closing tags 2019-06-06 11:48:45 -07:00
Sheetal Nandi
e4a2dd510f Handle export keyword of export assignment 2019-06-06 09:09:39 -07:00
Sheetal Nandi
1163a93ed6 Handle default keyword of default export 2019-06-05 16:35:29 -07:00
Sheetal Nandi
004488c0c9 Set declaration span only if its not same as own span 2019-06-04 15:37:43 -07:00
Sheetal Nandi
eaeeb06f9a Handle when declarationSpan from declarationNode is undefined 2019-06-04 13:48:13 -07:00
Sheetal Nandi
e41533acc7 Handle computed property names 2019-06-03 14:06:30 -07:00
Sheetal Nandi
0fee3b023d Handle destructuring assignments 2019-06-03 13:42:55 -07:00
Sheetal Nandi
dfb613c6d6 Use for-of declaration list + expression as span for preview 2019-05-31 16:02:31 -07:00
Sheetal Nandi
9703b3d6c1 Show property assignment for special property assignments in js files 2019-05-31 14:05:15 -07:00
Sheetal Nandi
6c04a0d14e For property name of binding element use binding element as preview node 2019-05-31 11:33:36 -07:00
Sheetal Nandi
15ce996cf5 Export assignment identifier use ExportAssigment as declaration 2019-05-31 11:09:22 -07:00
Sheetal Nandi
bbfbf8fa95 Use import export sepcifier as declaration for the property name of import export as well 2019-05-30 14:55:25 -07:00
Andrew Branch
b8dcf27c3e Merge pull request #31482 from andrewbranch/bug/31338
Organize imports: don’t delete import declarations used for module augmentation
2019-05-30 14:01:55 -07:00
Sheetal Nandi
6a961b5bc5 More tests 2019-05-28 16:14:44 -07:00
Daniel Rosenwasser
38f3b05cb1 31304 - Autocomplete for enum values fails when typing "/" (#31362)
31304 - Autocomplete for enum values fails when typing "/"
2019-05-24 16:17:25 -07:00
Sheetal Nandi
fd86f40d05 Include declarationSpan as relevant declaration span when defintion or other places are declaration name
Fixes #30849
2019-05-24 15:44:32 -07:00
Alexander T
8dba4d6467 Merge branch 'master' of https://github.com/Microsoft/TypeScript into bug/29880 2019-05-24 18:39:03 +03:00
Andrew Branch
f97f57c155 Fix containsPrecedingToken for tokens whose preceding token is a missing node 2019-05-23 12:15:50 -07:00
Alexander T
6cd992132d Add string properties declaration to the completion list 2019-05-23 11:08:19 +03:00
Andrew Branch
60d0bb9b19 Don’t touch imports used for module augmentation in non-declaration files since it could change JS emit 2019-05-22 11:37:35 -07:00
Ron Buckton
3d2af9ff33 Relocate Debug namespace to reduce duplication (#31524) 2019-05-22 11:20:29 -07:00
Sheetal Nandi
00cea41b65 Add sortText depending scope of symbols
Fixes #15024
2019-05-20 15:53:51 -07:00
Andrew Branch
6faeee449d Don’t remove imports that are used for module augmentation, just remove their import clauses 2019-05-20 14:49:28 -07:00
Andrew Branch
15daf42b2c Merge pull request #31028 from andrewbranch/feature/smart-select
Smart Select language service API
2019-05-16 09:45:05 -07:00
Daniel Rosenwasser
d484163d0f Merge pull request #31262 from rpgeeganage/new_keyword_consistent_resolve
Quick info on 'new' keyword should be the same as that of resolved expression
2019-05-15 00:36:38 -07:00
Alexander
8965650bc3 ignore trigger chars within a string literal 2019-05-12 23:14:18 +03:00
Wenlu Wang
714821fc97 add refactor of extract type (#30562)
* add basically implement

* add rename location and add testcase

* collection type arguments

* disallow infer type

* add support for typedef convert

* refactor info to make type safe

* disallow type pred

* avoid unnecessary branch

* disallow type query

* haha😂

Co-Authored-By: Kingwl <kingwenlu@gmail.com>

* Update src/services/refactors/extractType.ts

Co-Authored-By: Kingwl <kingwenlu@gmail.com>

* Update src/services/refactors/extractType.ts

Co-Authored-By: Kingwl <kingwenlu@gmail.com>

* add more tests

* add template tag support in jsdoc

* add support of type parameters constraint

* add more tests

* merge branch

* add more tests

* refactor and update function name
2019-05-07 08:26:53 -07:00
rpgeeganage
8f209be149 fixed the comments 2019-05-06 21:21:37 +02:00
rpgeeganage
578013b65c modified the service file 2019-05-05 19:01:14 +02:00