Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

swift syntax should be able to recover function parameters without argument labels #2254

Open
tayloraswift opened this issue Oct 2, 2023 · 2 comments
Labels
enhancement New feature or request SwiftParser Bugs in the (new) Parser written in Swift

Comments

@tayloraswift
Copy link
Member

Description

SwiftParser currently can’t handle DocC-style abridged signatures such as:

init(String.Index, x:(Int) -> Int) rethrows

as they are considered malformed parse trees.

more details at https://forums.swift.org/t/swiftsyntax-how-to-repair-abbreviated-function-signatures/67602

@tayloraswift tayloraswift added the enhancement New feature or request label Oct 2, 2023
@ahoppen
Copy link
Member

ahoppen commented Oct 2, 2023

Tracked in Apple’s issue tracker as rdar://116364935

@ahoppen ahoppen added the SwiftParser Bugs in the (new) Parser written in Swift label Oct 2, 2023
@AppAppWorks
Copy link
Contributor

I think this issue is similar to what #2727 has solved, maybe some generalization can be used to apply the solution to this issue too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request SwiftParser Bugs in the (new) Parser written in Swift
Projects
None yet
Development

No branches or pull requests

3 participants