8000 Bug in named arguments since 5.4.17, not fixed by fix in 5.4.19 · Issue #49118 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content
Bug in named arguments since 5.4.17, not fixed by fix in 5.4.19 #49118
Closed
@msteltenpool

Description

@msteltenpool

Symfony version(s) affected

5.4.17, 5.4.19

Description

The fix in named arguments in 5.4.17 triggered issues which 5.4.19 rectified. But seems to have not fixed all cases.

How to reproduce

services:
    _defaults:
        public: true
        bind:
            $a: 'A'

    App\Controller\IndexController:
        arguments:
            $b: 'B'

Above service configuration will trigger:

In DefinitionErrorExceptionPass.php line 54:
                                                                 
  Invalid constructor argument for service "App\Controller\IndexController": integer expected but found string "b". Check your service definition.  

Adding them both to bind or both to arguments will work (but is undesired).

Possible Solution

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0