Skip to content

Commit 05b35d6

Browse files
Merge branch '5.2' into 5.3
* 5.2: Backport type fixes Fix CS Avoid triggering the autoloader in Deprecation::isLegacy() fix markdown markup Backport type fixes uzb translation [DependencyInjection] Fix doc blocks [DependencyInjection] Turn $defaultDeprecationTemplate into a constant [Form] better form doc types to support static analysis
2 parents 162e886 + eb067d2 commit 05b35d6

File tree

2 files changed

+1
-29
lines changed

2 files changed

+1
-29
lines changed

OptionConfigurator.php

-4
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ public function __construct(string $name, OptionsResolver $resolver)
2828
/**
2929
* Adds allowed types for this option.
3030
*
31-
* @param string ...$types One or more accepted types
32-
*
3331
* @return $this
3432
*
3533
* @throws AccessException If called from a lazy option or normalizer
@@ -100,8 +98,6 @@ public function deprecated(string $package, string $version, $message = 'The opt
10098
/**
10199
* Sets the normalizer for this option.
102100
*
103-
* @param \Closure $normalizer The normalizer
104-
*
105101
* @return $this
106102
*
107103
* @throws AccessException If called from a lazy option or normalizer

OptionsResolver.php

+1-25
Original file line numberDiff line numberDiff line change
@@ -261,10 +261,6 @@ public function setDefault(string $option, $value)
261261
}
262262

263263
/**
264-
* Sets a list of default values.
265-
*
266-
* @param array $defaults The default values to set
267-
*
268264
* @return $this
269265
*
270266
* @throws AccessException If called from a lazy option or normalizer
@@ -284,8 +280,6 @@ public function setDefaults(array $defaults)
284280
* Returns true if {@link setDefault()} was called for this option.
285281
* An option is also considered set if it was set to null.
286282
*
287-
* @param string $option The option name
288-
*
289283
* @return bool Whether a default value is set
290284
*/
291285
public function hasDefault(string $option)
@@ -321,8 +315,6 @@ public function setRequired($optionNames)
321315
*
322316
* An option is required if it was passed to {@link setRequired()}.
323317
*
324-
* @param string $option The name of the option
325-
*
326318
* @return bool Whether the option is required
327319
*/
328320
public function isRequired(string $option)
@@ -349,8 +341,6 @@ public function getRequiredOptions()
349341
* to {@link setDefault()}. This option must be passed explicitly to
350342
* {@link resolve()}, otherwise an exception will be thrown.
351343
*
352-
* @param string $option The name of the option
353-
*
354344
* @return bool Whether the option is missing
355345
*/
356346
public function isMissing(string $option)
@@ -402,8 +392,6 @@ public function setDefined($optionNames)
402392
* Returns true for any option passed to {@link setDefault()},
403393
* {@link setRequired()} or {@link setDefined()}.
404394
*
405-
* @param string $option The option name
406-
*
407395
* @return bool Whether the option is defined
408396
*/
409397
public function isDefined(string $option)
@@ -516,9 +504,6 @@ public function isDeprecated(string $option): bool
516504
*
517505
* The resolved option value is set to the return value of the closure.
518506
*
519-
* @param string $option The option name
520-
* @param \Closure $normalizer The normalizer
521-
*
522507
* @return $this
523508
*
524509
* @throws UndefinedOptionsException If the option is undefined
@@ -560,10 +545,6 @@ public function setNormalizer(string $option, \Closure $normalizer)
560545
*
561546
* The resolved option value is set to the return value of the closure.
562547
*
563-
* @param string $option The option name
564-
* @param \Closure $normalizer The normalizer
565-
* @param bool $forcePrepend If set to true, prepend instead of appending
566-
*
567548
* @return $this
568549
*
569550
* @throws UndefinedOptionsException If the option is undefined
@@ -687,7 +668,6 @@ public function addAllowedValues(string $option, $allowedValues)
687668
* acceptable. Additionally, fully-qualified class or interface names may
688669
* be passed.
689670
*
690-
* @param string $option The option name
691671
* @param string|string[] $allowedTypes One or more accepted types
692672
*
693673
* @return $this
@@ -722,7 +702,6 @@ public function setAllowedTypes(string $option, $allowedTypes)
722702
* acceptable. Additionally, fully-qualified class or interface names may
723703
* be passed.
724704
*
725-
* @param string $option The option name
726705
* @param string|string[] $allowedTypes One or more accepted types
727706
*
728707
* @return $this
@@ -890,8 +869,6 @@ public function clear()
890869
* - Options have invalid types;
891870
* - Options have invalid values.
892871
*
893-
* @param array $options A map of option names to values
894-
*
895872
* @return array The merged and validated options
896873
*
897874
* @throws UndefinedOptionsException If an option name is undefined
@@ -953,8 +930,7 @@ public function resolve(array $options = [])
953930
/**
954931
* Returns the resolved value of an option.
955932
*
956-
* @param string $option The option name
957-
* @param bool $triggerDeprecation Whether to trigger the deprecation or not (true by default)
933+
* @param bool $triggerDeprecation Whether to trigger the deprecation or not (true by default)
958934
*
959935
* @return mixed The option value
960936
*

0 commit comments

Comments
 (0)