Alex Hoppen
155b0ce003
Merge pull request #2432 from ahoppen/suppress-superseded-sourcekitd-refactorings
...
Don’t show sourcekitd refactoring actions that have been superseded by swift-syntax refactoring actions
2026-01-16 07:42:33 +01:00
Karan Lokchandani
55d75954e5
Add if let to guard transform ( #2420 )
...
fixes: https://github.com/swiftlang/sourcekit-lsp/issues/1569
mostly works but not sure what to do with many edge cases and has a todo
for switch statements, also this will probably have conflicts with
https://github.com/swiftlang/sourcekit-lsp/pull/2406 marking as draft
till that merges and i can resolve the conflicts.
https://github.com/user-attachments/assets/a6d07f9d-6f09-4330-8cd0-2d24bd6973fb
---------
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-13 22:46:54 +01:00
Karan
40206bc7b8
cleanup demorgan
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-11 15:16:29 +05:30
Karan
babb3eaae2
Fix try fusion bug
2026-01-11 08:38:14 +05:30
Karan
04ca5078cc
Fix indentation and trivia not being attached to new negation
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-11 08:28:02 +05:30
Karan
50e073a876
propagate negation through try
2026-01-11 01:49:54 +05:30
Karan
b8395b5fb1
Fix trivia drop bug
2026-01-11 01:49:54 +05:30
Karan
8e21958760
Add more expr to whitelist
2026-01-11 01:49:54 +05:30
Alex Hoppen
fc876d01a4
Merge pull request #2433 from DPrakashhh/fix/no-computed-property-for-void-2430
...
Fix #2430 : Hide 'Convert to computed property' for Void functions
2026-01-08 16:59:14 +01:00
Alex Hoppen
69785ccb0a
Merge pull request #2435 from PhantomInTheWire/fix/indenation-codeable-structs
...
Fix JSON base indentation in Create Codable structs
2026-01-08 10:58:58 +01:00
Divya Prakash
a9331eacea
restored extensions and removed functions
2026-01-08 14:45:43 +05:30
Divya Prakash
e987d9478b
removed: helper extension
2026-01-08 09:59:57 +05:30
Divya Prakash
88e4d02b24
Made changes based on review
2026-01-07 21:59:46 +05:30
Karan
ae121bc112
use node.indentationOfFirstLine to simplify
2026-01-07 13:59:09 +05:30
Karan
2a64797c1a
Add more edge cases
2026-01-07 03:22:19 +05:30
Karan
e40a6a4e5a
Refactor initialIndentation in BasicFormat
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-07 02:52:47 +05:30
Karan
9046173872
Fix to use file indentation and not json identation
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-07 02:29:58 +05:30
Karan
28fb997071
Minor test and header fix
2026-01-07 01:02:15 +05:30
Karan
fb98b7b032
Fix JSON base indentation in Create Codable structs
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-06 18:05:28 +05:30
Karan
874aeb0c88
collect all valid code actions
2026-01-06 16:47:22 +05:30
Karan
906421662b
refactor to avoid cast calls
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-06 16:04:30 +05:30
Karan
80657b1827
reduce access level of DeMorganTransformer to package
2026-01-06 15:46:50 +05:30
Karan
60da2439cb
feat(swift-language-service): implement De Morgan's Law code action
...
Signed-off-by: Karan <karanlokchandani@protonmail.com >
2026-01-06 15:18:38 +05:30
Divya Prakash
f095486c91
Fix #2430 : Hide 'Convert to computed property' for Void functions
2026-01-06 14:15:00 +05:30
Alex Hoppen
529c9fa7e2
Don’t show sourcekitd refactoring actions that have been superseded by swift-syntax refactoring actions
...
For now, this is only the action to add thousands separators to integer literals but hopefully this list will grow as we translate more refactoring actions to swift-syntax.
2026-01-06 09:07:38 +01:00
Anthony Latsis
6b19657739
Enable ExistentialAny
2025-12-02 12:27:27 +00:00
Vladimir Gusev
9647dcc3dc
Convert between computed properties and zero-parameters functions
2025-11-14 12:00:46 +03:00
Owen Voorhees
f04b971726
Adopt swift-tools-protocols
2025-10-31 14:11:11 -07:00
Alex Hoppen
4c957506e8
Add a code action to remove unused imports in a source file
...
The idea is pretty simple: When `MemberImportVisibility` is enabled, we know that imports can only affect the current source file. So, we can just try and remove every single `import` declaration in the file, check if a new error occurred and if not, we can safely remove it.
2025-10-22 23:56:09 +02:00
Alex Hoppen
aa7ff70042
Merge pull request #2300 from ahoppen/drop-6.1
...
Drop support for building with Swift 6.1
2025-09-22 14:16:39 +02:00
Alex Hoppen
c7ca73aecb
Drop support for building with Swift 6.1
...
Swift 6.2 has been released, so we no longer need to support building and testing SourceKit-LSP using Swift 6.1
2025-09-20 16:37:24 +02:00
Ben Barham
1313ef4520
Remove SwiftPM dependency from SwiftLanguageService
...
This was needed for the package manifest refactorings, but they're
now provided by swift-syntax instead.
2025-09-15 19:48:46 -07:00
Pavel Yaskevich
061c7a094b
[SwiftLanguageService] CodeActions: Use asWorkspaceEdit in more places
2025-08-26 14:04:36 -07:00
Pavel Yaskevich
0594744a93
[SwiftLanguageService] Adopt changes to package manifest refactoring actions
...
Previously package manifest refactoring actions conformed to a custom
refactoring provider and produced a `PackageEdit` that, in addition to
manifest file changes, included a list of auxiliary files. This is no
longer the case and all package manifest refactoring actions are now
responsible only for manifest file transformations, the rest is handled
separately.
2025-08-26 13:00:00 -07:00
Pavel Yaskevich
28ec028ef5
[SwiftLanguageService] Adopt to throwing refactoring actions
...
`EditRefactoringProvider.textRefactor` and `EditRefactoringProvider.refactor`
requirements are now throwing and produce a non-optional type.
2025-08-22 23:27:39 -07:00
Alex Hoppen
c14f5dd7fd
Move SwiftLanguageService into its own module
2025-08-14 11:12:31 +02:00