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

Add Constructor DSL up to 22 parameters #1359

Conversation

marcellogalhardo
Copy link
Contributor

@marcellogalhardo marcellogalhardo commented Jun 6, 2022

Add constructor DSL up to 22 parameters for: new, singleOf, factoryOf, scopedOf, viewModelOf, workerOf, fragmentOf. It also simplifies the constructor's internal implementation by inlining withOptions (if empty, the inlined options parameter should not create an instance and thus performance should not be impacted).

Note 22 was chosed due to the Kotlin STD Lib using that number. To keep it synchronized with the STD Lib, we won't be adding more than 22.

Fixes #1342.

@arnaudgiuliani arnaudgiuliani added this to the 3.3.0 milestone Jun 27, 2022
@arnaudgiuliani arnaudgiuliani added core status:checking currently in analysis - discussion or need more detailed specs labels Jun 27, 2022
@arnaudgiuliani arnaudgiuliani changed the base branch from main to core/3.3.0 December 13, 2022 10:12
@arnaudgiuliani arnaudgiuliani merged commit e5bd2d9 into InsertKoinIO:core/3.3.0 Dec 13, 2022
@arnaudgiuliani
Copy link
Member

thanks @marcellogalhardo for your contribution 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core status:checking currently in analysis - discussion or need more detailed specs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add singleOf for 11..22 params
2 participants