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

Remove overhead added by *Scope classes in Kotlin DSL via Kotlin 1.3 inline data classes #9227

Open
bamboo opened this issue Apr 30, 2018 · 4 comments
Labels
a:performance-improvement Performance improvement potential in:kotlin-dsl
Milestone

Comments

@bamboo
Copy link
Member

bamboo commented Apr 30, 2018

According to this blog post Kotlin 1.3 will introduce inline data classes.

Inline data classes would allow us to remove the overhead from types such as DependencyHandlerScope, NamedDomainObjectContainerScope, etc whose only purpose is to wrap a Gradle type in order to provide a Kotlin-friendly API.

@eskatos eskatos changed the title Remove overhead added by *Scope classes via Kotlin 1.3 inline data classes Remove overhead added by *Scope classes in Kotlin DSL via Kotlin 1.3 inline data classes Apr 19, 2019
@eskatos eskatos transferred this issue from gradle/kotlin-dsl-samples Apr 25, 2019
@stale
Copy link

stale bot commented Sep 6, 2020

This issue has been automatically marked as stale because it has not had recent activity. Given the limited bandwidth of the team, it will be automatically closed if no further activity occurs. If you're interested in how we try to keep the backlog in a healthy state, please read our blog post on how we refine our backlog. If you feel this is something you could contribute, please have a look at our Contributor Guide. Thank you for your contribution.

@stale stale bot added the stale label Sep 6, 2020
@Tapchicoma
Copy link

Still would be nice to have this performance optimization.

@eskatos
Copy link
Member

eskatos commented Jan 16, 2023

This would be a binary breaking change and should be done on a major release.

Doing this we could get rid of the whole org.gradle.kotlin.dsl.delegates internal package.

@eskatos eskatos added this to the 9.0 RC1 milestone Jan 16, 2023
@ov7a ov7a added the a:performance-improvement Performance improvement potential label Aug 8, 2023
@eskatos
Copy link
Member

eskatos commented Aug 9, 2023

Another option to completely get rid of *Scope would be to use Kotlin context receivers which will be ABI stable in Kotlin 2.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:performance-improvement Performance improvement potential in:kotlin-dsl
Projects
None yet
Development

No branches or pull requests

7 participants