Skip to content

Commit 9978184

Browse files
committed
[DI] removed tagged
1 parent e7ce055 commit 9978184

File tree

5 files changed

+2
-22
lines changed

5 files changed

+2
-22
lines changed

src/Symfony/Component/DependencyInjection/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ CHANGELOG
1111
* removed support for short factory/configurator syntax from `YamlFileLoader`
1212
* removed `ResettableContainerInterface`, use `ResetInterface` instead
1313
* added argument `$returnsClone` to `Definition::addMethodCall()`
14+
* removed `tagged`, use `tagged_iterator` instead
1415

1516
4.4.0
1617
-----

src/Symfony/Component/DependencyInjection/Loader/Configurator/ContainerConfigurator.php

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -113,18 +113,6 @@ function iterator(array $values): IteratorArgument
113113
return new IteratorArgument(AbstractConfigurator::processValue($values, true));
114114
}
115115

116-
/**
117-
* Creates a lazy iterator by tag name.
118-
*
119-
* @deprecated since Symfony 4.4, to be removed in 5.0, use "tagged_iterator" instead.
120-
*/
121-
function tagged(string $tag, string $indexAttribute = null, string $defaultIndexMethod = null): TaggedIteratorArgument
122-
{
123-
@trigger_error(__NAMESPACE__.'\tagged() is deprecated since Symfony 4.4 and will be removed in 5.0, use '.__NAMESPACE__.'\tagged_iterator() instead.', E_USER_DEPRECATED);
124-
125-
return new TaggedIteratorArgument($tag, $indexAttribute, $defaultIndexMethod);
126-
}
127-
128116
/**
129117
* Creates a lazy iterator by tag name.
130118
*/

src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -544,9 +544,6 @@ private function getArgumentsAsPhp(\DOMElement $node, $name, $file, $lowercase =
544544
throw new InvalidArgumentException(sprintf('Tag "<%s>" with type="service_locator" only accepts maps of type="service" references in "%s".', $name, $file));
545545
}
546546
break;
547-
case 'tagged':
548-
@trigger_error(sprintf('Type "%s" of tag <%s> in "%s" is deprecated since Symfony 4.4 and will be removed in 5.0, use "tagged_iterator" instead.', $arg->getAttribute('type'), $name, $file), E_USER_DEPRECATED);
549-
// no break
550547
case 'tagged_iterator':
551548
case 'tagged_locator':
552549
$type = $arg->getAttribute('type');

src/Symfony/Component/DependencyInjection/Loader/YamlFileLoader.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -717,11 +717,7 @@ private function resolveServices($value, $file, $isParameter = false)
717717
throw new InvalidArgumentException(sprintf('"!service_locator" tag only accepts maps of "@service" references in "%s".', $file));
718718
}
719719
}
720-
if (\in_array($value->getTag(), ['tagged', 'tagged_iterator', 'tagged_locator'], true)) {
721-
if ('tagged' === $value->getTag()) {
722-
@trigger_error('"!tagged" is deprecated since Symfony 4.4 and will be removed in 5.0, use "!tagged_iterator" instead.', E_USER_DEPRECATED);
723-
}
724-
720+
if (\in_array($value->getTag(), ['tagged_iterator', 'tagged_locator'], true)) {
725721
$forLocator = 'tagged_locator' === $value->getTag();
726722

727723
if (\is_string($argument) && $argument) {

src/Symfony/Component/DependencyInjection/Loader/schema/dic/services/services-1.0.xsd

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,8 +264,6 @@
264264
<xsd:enumeration value="constant" />
265265
<xsd:enumeration value="iterator" />
266266
<xsd:enumeration value="service_locator" />
267-
<!-- "tagged" is deprecated since Symfony 4.4 and will be removed in 5.0, use "tagged_iterator" instead. -->
268-
<xsd:enumeration value="tagged" />
269267
<xsd:enumeration value="tagged_iterator" />
270268
<xsd:enumeration value="tagged_locator" />
271269
</xsd:restriction>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy