You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add a refactoring action that converts T! to T? for all types T. At first blush, this appears to be possible by converting ImplicitlyUnwrappedOptionalTypeSyntax nodes to OptionalTypeSyntax nodes without changing the underlying type syntax for T.
As an aside, I think we may not necessarily want to go the other way (T? to T!) since it's generally not great Swift style.
changed the title [-]Add a Refactoring Action for Converting IUOs to Proper Optionals[/-][+]Add a Refactoring Action for Converting implicitly unwrapped optionals to proper optionals[/+]on Jun 8, 2024
changed the title [-]Add a Refactoring Action for Converting implicitly unwrapped optionals to proper optionals[/-][+]Add a Refactoring Action for Converting Implicitly Unwrapped Optionals to Proper Optionals[/+]on Jun 8, 2024
Great to hear that you’re interested in contributing. Looks like #1539 has been stale for a while, so I think you could pick it up. That conversation has quite a bit of context as well and I think it turned out that the implementation wouldn’t be trivial because it would be the first global refactoring action except for global rename (which has quite a bit of bespoke logic). But I don’t want to discourage you from trying 😉
Activity
ahoppen commentedon May 18, 2024
Synced to Apple’s issue tracker as rdar://128310729
[-]Add a Refactoring Action for Converting IUOs to Proper Optionals[/-][+]Add a Refactoring Action for Converting implicitly unwrapped optionals to proper optionals[/+][-]Add a Refactoring Action for Converting implicitly unwrapped optionals to proper optionals[/-][+]Add a Refactoring Action for Converting Implicitly Unwrapped Optionals to Proper Optionals[/+]Convert implicitly unwrapped optionals to proper optionals swiftlang#…
Convert implicitly unwrapped optionals to proper optionals swiftlang#…
AbdAlRahmanGad commentedon Feb 28, 2025
Hi @ahoppen,
I'm trying to contribute to
sourcekit-lsp
.Could you please point me to where should I implement this change? and how to test the refactoring action?
Steps I've taken so far, I've fetched the code and built
sourcekit-lsp
successfully.AbdAlRahmanGad commentedon Feb 28, 2025
I've just noticed that there is an old draft PR. Should I work on top of it or should I look for another issue?
ahoppen commentedon Feb 28, 2025
Great to hear that you’re interested in contributing. Looks like #1539 has been stale for a while, so I think you could pick it up. That conversation has quite a bit of context as well and I think it turned out that the implementation wouldn’t be trivial because it would be the first global refactoring action except for global rename (which has quite a bit of bespoke logic). But I don’t want to discourage you from trying 😉
AbdAlRahmanGad commentedon Mar 1, 2025
Is it okay if I worked on issue #1246 as it's the only
good first issue
right now?ahoppen commentedon Mar 3, 2025
Yes, please go ahead