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

Functional Bean Definition DSL for noarg functions #23395

Closed
juergenzimmermann opened this issue Aug 1, 2019 · 1 comment
Closed

Functional Bean Definition DSL for noarg functions #23395

juergenzimmermann opened this issue Aug 1, 2019 · 1 comment
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: bug A general bug
Milestone

Comments

@juergenzimmermann
Copy link

Affects: 5.2.0.M3

When using the Kotlin-based Functional Bean Definition DSL I'm having a definition like this one:

val beans = beans {
    bean<CustomerService>()
    bean<CustomerHandler>()

    // 3 args resp. 1 arg
    bean(::router)    
    bean(::securityWebFilterChain)

    // userDetailsService has no args
    // bean(::userDetailsService) DOESN'T COMPILE
    bean { userDetailsService() }
}

For readability reasons it would be nice to also use a function reference when the bean function has no arguments.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Aug 1, 2019
@sdeleuze sdeleuze added in: core Issues in core modules (aop, beans, core, context, expression) type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Jan 13, 2020
@sdeleuze sdeleuze added this to the 5.2.3 milestone Jan 13, 2020
@sdeleuze sdeleuze self-assigned this Jan 13, 2020
@sdeleuze
Copy link
Contributor

Thanks for reporting it and sorry for the lag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: bug A general bug
Projects
None yet
Development

No branches or pull requests

3 participants