File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -600,15 +600,16 @@ Autowiring will automatically call *any* method with the ``#[Required]`` attribu
600
600
above it, autowiring each argument. If you need to manually wire some of the arguments
601
601
to a method, you can always explicitly :doc: `configure the method call </service_container/calls >`.
602
602
603
- If you need to
8000
stay compatible with PHP 7 and thus cannot use attributes, you can use
604
- the ``@required `` annotation instead.
603
+ If your PHP version doesn't support attributes (they were introduced in PHP 8),
604
+ you can use the ``@required `` annotation instead.
605
605
606
606
.. versionadded :: 5.2
607
607
608
608
The ``#[Required] `` attribute was introduced in Symfony 5.2.
609
609
610
- Despite property injection has some :ref: `drawbacks <property-injection >`, autowiring with ``#[Required] ``
611
- or ``@required `` can also be applied to public typed properties::
610
+ Despite property injection has some :ref: `drawbacks <property-injection >`,
611
+ autowiring with ``#[Required] `` or ``@required `` can also be applied to public
612
+ typed properties::
612
613
613
614
.. configuration-block ::
614
615
You can’t perform that action at this time.
0 commit comments