Skip to content

Java2Swift: Factor Java class translation into its own type & file #120

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

Merged

Conversation

DougGregor
Copy link
Member

The main function for translating a Java class into a sequence of Swift declarations was very large and very tangled. Refactor it into a separate class that more deliberately separates the analysis of the Java class (picking out what needs to be translated) from the actual rendering of the Swift declarations, then breaks that rendering down into more digestible pieces.

No (intended) functionality change here: this is cleanup to make it easier to implement some upcoming improvements.

The main function for translating a Java class into a sequence of Swift
declarations was very large and very tangled. Refactor it into a separate
class that more deliberately separates the analysis of the Java class
(picking out what needs to be translated) from the actual rendering of
the Swift declarations, then breaks that rendering down into more
digestible pieces.

No (intended) functionality change here: this is cleanup to make it
easier to implement some upcoming improvements.
@DougGregor DougGregor merged commit 79a7401 into swiftlang:main Oct 28, 2024
11 checks passed
@DougGregor DougGregor deleted the java2swift-class-translation-refactor branch October 28, 2024 05:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant