Skip to content

Commit a5e0f07

Browse files
committed
Merge branch '4.2'
* 4.2: Recommend including the package name in messages add blank line before directive
2 parents 4045a40 + a7d13cf commit a5e0f07

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

contributing/code/conventions.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ A feature is marked as deprecated by adding a ``@deprecated`` phpdoc to
9191
relevant classes, methods, properties, ...::
9292

9393
/**
94-
* @deprecated since version 2.8, to be removed in 3.0. Use XXX instead.
94+
* @deprecated since vendor-name/package-name 2.8, to be removed in 3.0. Use XXX instead.
9595
*/
9696

9797
The deprecation message should indicate the version when the class/method was
@@ -102,7 +102,7 @@ A PHP ``E_USER_DEPRECATED`` error must also be triggered to help people with
102102
the migration starting one or two minor versions before the version where the
103103
feature will be removed (depending on the criticality of the removal)::
104104

105-
@trigger_error('XXX() is deprecated since version 2.8 and will be removed in 3.0. Use XXX instead.', E_USER_DEPRECATED);
105+
@trigger_error('XXX() is deprecated since vendor-name/package-name 2.8 and will be removed in 3.0. Use XXX instead.', E_USER_DEPRECATED);
106106

107107
Without the `@-silencing operator`_, users would need to opt-out from deprecation
108108
notices. Silencing swaps this behavior and allows users to opt-in when they are

contributing/code/standards.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ short example containing most features described below::
6767
*/
6868
public function someDeprecatedMethod()
6969
{
70-
@trigger_error(sprintf('The %s() method is deprecated since version 2.8 and will be removed in 3.0. Use Acme\Baz::someMethod() instead.', __METHOD__), E_USER_DEPRECATED);
70+
@trigger_error(sprintf('The %s() method is deprecated since vendor-name/package-name 2.8 and will be removed in 3.0. Use Acme\Baz::someMethod() instead.', __METHOD__), E_USER_DEPRECATED);
7171

7272
return Baz::someMethod();
7373
}

forms.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -722,6 +722,7 @@ There's a lot more to learn and a lot of *powerful* tricks in the form system.
722722

723723
Learn more
724724
----------
725+
725726
.. toctree::
726727
:maxdepth: 1
727728
:glob:

service_container/alias_private.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ or you decided not to maintain it anymore), you can deprecate its definition:
293293
294294
# config/services.yaml
295295
App\Service\OldService:
296-
deprecated: The "%service_id%" service is deprecated since 2.8 and will be removed in 3.0.
296+
deprecated: The "%service_id%" service is deprecated since vendor-name/package-name 2.8 and will be removed in 3.0.
297297
298298
.. code-block:: xml
299299
@@ -305,7 +305,7 @@ or you decided not to maintain it anymore), you can deprecate its definition:
305305
306306
<services>
307307
<service id="App\Service\OldService">
308-
<deprecated>The "%service_id%" service is deprecated since 2.8 and will be removed in 3.0.</deprecated>
308+
<deprecated>The "%service_id%" service is deprecated since vendor-name/package-name 2.8 and will be removed in 3.0.</deprecated>
309309
</service>
310310
</services>
311311
</container>
@@ -319,7 +319,7 @@ or you decided not to maintain it anymore), you can deprecate its definition:
319319
->register(OldService::class)
320320
->setDeprecated(
321321
true,
322-
'The "%service_id%" service is deprecated since 2.8 and will be removed in 3.0.'
322+
'The "%service_id%" service is deprecated since vendor-name/package-name 2.8 and will be removed in 3.0.'
323323
)
324324
;
325325

0 commit comments

Comments
 (0)