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

[New Rule]: Control ordering of closure attributes #1905

Open
jshier opened this issue Oct 18, 2024 · 1 comment
Open

[New Rule]: Control ordering of closure attributes #1905

jshier opened this issue Oct 18, 2024 · 1 comment

Comments

@jshier
Copy link

jshier commented Oct 18, 2024

There doesn't currently seem to be a rule to normalize closure attribute order.

func later(_ perform: @escaping @Sendable @isolated(any) () -> Void) {}

That's my preferred styles, but controlling the order in general would be the goal. There are also now keywords that need to be taken into account as well.

func later(_ perform: sending @escaping @isolated(any) () async -> Void) {}
@dmallory
Copy link

dmallory commented Nov 13, 2024

Our team would also use this. Particularly with Swift 6 adoption there are a huge number of concurrency-related attributes and keywords being adding across the codebase and it would be wonderful to enforce the order for all of it, similar to modifierOrder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants