Skip to content

Commit 673d592

Browse files
committed
minor #22913 [Yaml] Deprecate tags using colon (GuilhemN)
This PR was squashed before being merged into the 3.4 branch (closes #22913). Discussion ---------- [Yaml] Deprecate tags using colon | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | no | New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files --> | BC breaks? | no | Deprecations? | yes | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | Using a colon in a tag doesn't look like yaml and causes trouble (see symfony/symfony#22878), so I propose to just deprecate these tags in favor of more consistent tags. ```yml - !php/const:PHP_INT_MAX - !php/object:O:30:"Symfony\Component\Yaml\Tests\A":1:{s:1:"a";s:3:"foo";} ``` would become ```yml - !php/const PHP_INT_MAX - !php/object O:30:"Symfony\Component\Yaml\Tests\A":1:{s:1:"a";s:3:"foo";} ``` Commits ------- 9815af3 [Yaml] Deprecate tags using colon
2 parents 5b9a29f + 1f8902e commit 673d592

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Tests/Fixtures/yaml/services2.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ parameters:
55
- false
66
- 0
77
- 1000.3
8-
- !php/const:PHP_INT_MAX
8+
- !php/const PHP_INT_MAX
99
bar: foo
1010
escape: '@@escapeme'
1111
foo_bar: '@foo_bar'

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"psr/container": "^1.0"
2121
},
2222
"require-dev": {
23-
"symfony/yaml": "~3.3|~4.0",
23+
"symfony/yaml": "~3.4|~4.0",
2424
"symfony/config": "~3.3|~4.0",
2525
"symfony/expression-language": "~2.8|~3.0|~4.0"
2626
},
@@ -35,7 +35,7 @@
3535
"symfony/config": "<3.3.1",
3636
"symfony/finder": "<3.3",
3737
"symfony/proxy-manager-bridge": "<3.4",
38-
"symfony/yaml": "<3.3"
38+
"symfony/yaml": "<3.4"
3939
},
4040
"provide": {
4141
"psr/container-implementation": "1.0"

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