Joscha Feth
ee429ef2ea
use state
2018-04-13 11:39:29 +10:00
Joscha Feth
4da2e5eda3
fix: do not match MySymbol.import("mod")
2018-04-12 19:31:07 +10:00
Andy
edcf087145
Fix bug: isSymbolReferencedInFile should return true for shorthand property assignment ( #23314 )
...
* Fix bug: isSymbolReferencedInFile should return true for shorthand property assignment
* Also test for export specifier
2018-04-11 19:01:30 -07:00
Andy
b0552b089d
Don't include "/index" in import from @types even with classic resolution ( #23347 )
2018-04-11 16:22:10 -07:00
Andy
28455c65b3
patternMatcher: Return single best match instead of list ( #23166 )
2018-04-11 15:35:22 -07:00
Andy
f6b206a75a
When testing references, also test documentHighlights respects filesToSearch ( #23306 )
...
* When testing references, also test documentHighlights respects filesToSearch
* Fix handling for redirects and move assertion inside getDocumentHighlights
* Add another assert
2018-04-11 14:07:22 -07:00
Andy
fef28665f7
generateGetAccessorAndSetAccessor: Fix typos and use type predicate ( #23310 )
2018-04-11 13:21:47 -07:00
Andy
f479de6d02
patternMatcher: Just return 'undefined' for an invalid pattern ( #23237 )
...
* patternMatcher: Just return 'undefined' for an invalid pattern
* Fix tests
2018-04-10 14:38:16 -07:00
Andy
4b706fc479
Add 'disableSuggestions' to UserPreferences ( #23283 )
...
* Add 'disableSuggestions' to UserPreferences
* Make mergeMapLikes return a new object
* Avoid additional clone
* mergeMapLikes -> object spread
2018-04-10 11:53:24 -07:00
Wenlu Wang
9c0671d661
add refactor of convert private field to getter and setter ( #22143 )
...
* add refactor of convert private field to getter and setter
* fix refactor
* stash
* refactor accessor generate
* revert merge union type
* refeactor and accept baseline
* add support of PropertyAssignment and StringLiteral
* add support for js file
* allow static modifier in js file
2018-04-10 11:51:41 -07:00
Andy
ce5d22fef0
Fix bug: don't insert a semicolon when inserting a FunctionDeclaration ( #23240 )
2018-04-09 15:03:24 -07:00
Andy
e858de9520
Simplify handling of parameter properties in forEachRelatedSymbol ( #23213 )
...
* Simplify handling of parameter properties in forEachRelatedSymbol
* Add assert for other paramProps symbol
2018-04-09 13:26:10 -07:00
Andy
98a5e5cc0d
Prioritize spelling fix over add-missing-member fix ( #23268 )
2018-04-09 13:23:11 -07:00
Andy
998beadba2
Support goto-definition for index signatures ( #23220 )
...
* Support goto-definition for index signatures
* Use checker.getIndexInfoOfType
* Handle undefined info.declaration
2018-04-09 12:48:41 -07:00
Andy
9762598775
findAllReferences: forEachRelatedSymbol can always include shorthand destructuring ( #23223 )
...
* findAllReferences: forEachRelatedSymbol can always include shorthand destructuring
* Update rename tests
2018-04-06 16:30:55 -07:00
Andy
70682b7799
Clean up code for nonrelative path completions ( #23150 )
...
* Clean up code for nonrelative path completions
* Remove unnecessary test and simplify based on that
* More code review
* Call getCompletionEntriesFromTypings unconditionally
2018-04-06 12:19:08 -07:00
Andy
2b59c9a0d7
Don't add import completion for re-export with different name ( #23211 )
2018-04-06 10:05:38 -07:00
Andy
aa8631de98
findAllReferences: Share code between populateSearchSymbolSet and getRelatedSymbol ( #23028 )
2018-04-05 15:00:14 -07:00
Andy
24842b4002
When --noUnusedLocals/--noUnusedParameters is disabled, add suggestions instead of errors ( #22361 )
...
* When --noUnusedLocals/--noUnusedParameters is disabled, add suggestions instead of errors
* Improve performance: do not add unused suggestion diagnostics unless asking for a suggestion
* Add "unused" flag to diagnostics
* Code review
* reportsUnused -> reportsUnnecessary
* Fix test
2018-04-05 12:33:00 -07:00
Andy
f61f12613c
findAllReferences: Be consistent how we handle unions in root symobls ( #23002 )
2018-04-05 10:55:55 -07:00
Andy
7520f9578b
Fix bug: <div a="1" b/**/ > is not a jsx initializer ( #23138 )
2018-04-05 08:30:02 -07:00
Andrew Casey
855171bde5
Introduce a --syntaxOnly server mode
...
1. Disable the LS in all projects
2. Don't create Program objects
3. Ignore config files
2018-04-04 16:44:15 -07:00
Andy
5b928a3d00
patternMatcher: Use helper functions to simplify loops over strings ( #23095 )
...
* patternMatcher: Use helper functions to simplify loops over strings
* Fix bug
2018-04-04 08:37:14 -07:00
Andy
4aeb295e3a
completions: Properly handle preferences.includeCompletionsWithInsertText ( #23092 )
2018-04-04 08:36:48 -07:00
Andy
1e227c6d77
Add type predicate helper functions to Type ( #23066 )
2018-04-04 08:10:09 -07:00
Mohamed Hegazy
db74229a89
Merge pull request #19317 from igelbox/fix-insert-space-after-function-generic
...
Fixed incorrect insertSpaceBeforeFunctionParenthesis behavior on funtions with type-arguments
2018-04-03 16:11:30 -07:00
Wesley Wigham
c676893dc9
SyntaxKind.ImportTypeNode -> SyntaxKind.ImportType ( #23120 )
2018-04-03 13:32:03 -07:00
Mohamed Hegazy
84548d5c9b
Merge pull request #22049 from Kingwl/spelling-fix
...
replace element access if suggession is not a valid identifier
2018-04-03 13:29:43 -07:00
Wesley Wigham
a81a645128
Enable member completions for import types ( #23085 )
...
* Enable member completions for import types
* Add missing semicolon
* Compact statements
* Ye doth compacteth too much
* Handle class accesibility
2018-04-03 11:53:01 -07:00
王文璐
414266cc32
Merge branch 'master' into spelling-fix
2018-04-03 10:51:40 +08:00
Andy
92dfde0067
matchTextChunk: combine a) and b) cases ( #23083 )
2018-04-02 18:09:09 -07:00
Andy
1e04bd4168
Support completions for members with symbol names ( #23091 )
2018-04-02 18:08:00 -07:00
Andy
955542df8e
Simplify matchTextChunk ( #23081 )
2018-04-02 16:20:07 -07:00
Wesley Wigham
fd553df3a6
Path completions for import types ( #23082 )
...
* Path completions
* Add missing flag to test
* Minify test, fix lint
2018-04-02 16:15:50 -07:00
Andy
7eaad14bf9
Work around bug with global completion with invalid identifier ( #23086 )
2018-04-02 14:58:08 -07:00
Andy
8e14ac7d51
Improve string literal completions from a signature ( #23062 )
2018-04-02 13:01:31 -07:00
Andy
65323e046a
Unclosurefy patternMatcher ( #23071 )
2018-04-02 12:21:48 -07:00
Nathan Shively-Sanders
d3e0929b14
Mark js-assignment functions' symbols as methods ( #23078 )
...
This make display more accurate:
1. The functions now print as methods
2. When the type of the function references the class, the type of the
function itself is now printed correctly instead of as `any`.
2018-04-02 12:17:35 -07:00
Andy
72e92a0558
Remove unused properties from patternMatcher ( #23076 )
2018-04-02 12:02:35 -07:00
Andy
8cdd1aecca
Simplify 'bestMatchKind' ( #23073 )
2018-04-02 11:57:19 -07:00
Andy
d5142a7f45
Don't offer import completions in non-module files unless "--module" is set ( #22951 )
...
* Don't offer import completions in non-module files unless "--module" is set
* Even smarter shouldOfferImportCompletions
2018-04-02 10:21:14 -07:00
Andy
ea65f21677
textChanges: Don't crash when inserting type annotation on function with no parens ( #23034 )
2018-04-02 08:41:22 -07:00
Andy
86a8e269fa
Add 'getNameFromPropertyName' helper ( #23036 )
2018-04-02 08:14:15 -07:00
Arthur Ozga
9dd3ef4205
Merge pull request #22849 from aozgaa/dev/aozgaa/cSharpObjLiteralFormatting
...
CSharp Style Object Literal Formatting
2018-03-30 15:45:46 -07:00
Andy
e14964169a
Combine getDocumentationComment implementations ( #22722 )
2018-03-30 09:43:12 -07:00
Andy
a5df301dec
Simplify getPropertySymbolsFromBaseTypes ( #23004 )
2018-03-30 09:42:49 -07:00
Mohamed Hegazy
b47c1fd5a1
Merge pull request #22593 from Kingwl/module-spelling-fix
...
add spelling suggestion support for module
2018-03-29 16:56:43 -07:00
Arthur Ozga
95a69cbeb4
Merge branch 'master' into dev/aozgaa/cSharpObjLiteralFormatting
2018-03-29 16:10:33 -07:00
Wesley Wigham
1e5641ba8e
Mangle comment for sorcery ( #23006 )
2018-03-29 16:05:31 -07:00
Andy
4a39caffd4
Use isExternalModuleImportEquals in one more place ( #22417 )
2018-03-29 15:40:25 -07:00