Skip to content

Commit d2cddff

Browse files
Cleanup more @return annotations
1 parent 0e3758c commit d2cddff

File tree

7 files changed

+16
-14
lines changed

7 files changed

+16
-14
lines changed

Caster/Caster.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class Caster
4242
*
4343
* @param bool $hasDebugInfo Whether the __debugInfo method exists on $obj or not
4444
*
45-
* @return array The array-cast of the object, with prefixed dynamic properties
45+
* @return array
4646
*/
4747
public static function castObject(object $obj, string $class, bool $hasDebugInfo = false, string $debugClass = null): array
4848
{
@@ -119,7 +119,7 @@ public static function castObject(object $obj, string $class, bool $hasDebugInfo
119119
* @param string[] $listedProperties List of properties to exclude when Caster::EXCLUDE_VERBOSE is set, and to preserve when Caster::EXCLUDE_NOT_IMPORTANT is set
120120
* @param int &$count Set to the number of removed properties
121121
*
122-
* @return array The filtered array
122+
* @return array
123123
*/
124124
public static function filter(array $a, int $filter, array $listedProperties = [], ?int &$count = 0): array
125125
{

Cloner/AbstractCloner.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ public function setMinDepth(int $minDepth)
260260
* @param mixed $var Any PHP variable
261261
* @param int $filter A bit field of Caster::EXCLUDE_* constants
262262
*
263-
* @return Data The cloned variable represented by a Data object
263+
* @return Data
264264
*/
265265
public function cloneVar($var, int $filter = 0)
266266
{
@@ -297,7 +297,7 @@ public function cloneVar($var, int $filter = 0)
297297
*
298298
* @param mixed $var Any PHP variable
299299
*
300-
* @return array The cloned variable represented in an array
300+
* @return array
301301
*/
302302
abstract protected function doClone($var);
303303

@@ -306,7 +306,7 @@ abstract protected function doClone($var);
306306
*
307307
* @param bool $isNested True if the object is nested in the dumped structure
308308
*
309-
* @return array The object casted as array
309+
* @return array
310310
*/
311311
protected function castObject(Stub $stub, bool $isNested)
312312
{
@@ -365,7 +365,7 @@ protected function castObject(Stub $stub, bool $isNested)
365365
*
366366
* @param bool $isNested True if the object is nested in the dumped structure
367367
*
368-
* @return array The resource casted as array
368+
* @return array
369369
*/
370370
protected function castResource(Stub $stub, bool $isNested)
371371
{

Cloner/ClonerInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ interface ClonerInterface
2121
*
2222
* @param mixed $var Any PHP variable
2323
*
24-
* @return Data The cloned variable represented by a Data object
24+
* @return Data
2525
*/
2626
public function cloneVar($var);
2727
}

Cloner/Data.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public function __construct(array $data)
3636
}
3737

3838
/**
39-
* @return string|null The type of the value
39+
* @return string|null
4040
*/
4141
public function getType()
4242
{
@@ -65,9 +65,11 @@ public function getType()
6565
}
6666

6767
/**
68+
* Returns a native representation of the original value.
69+
*
6870
* @param array|bool $recursive Whether values should be resolved recursively or not
6971
*
70-
* @return string|int|float|bool|array|Data[]|null A native representation of the original value
72+
* @return string|int|float|bool|array|Data[]|null
7173
*/
7274
public function getValue($recursive = false)
7375
{
@@ -256,7 +258,7 @@ public function withContext(array $context)
256258
*
257259
* @param string|int $key The key to seek to
258260
*
259-
* @return static|null Null if the key is not set
261+
* @return static|null
260262
*/
261263
public function seek($key)
262264
{

Dumper/AbstractDumper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ protected function echoLine(string $line, int $depth, string $indentPad)
180180
/**
181181
* Converts a non-UTF-8 string to UTF-8.
182182
*
183-
* @return string|null The string converted to UTF-8
183+
* @return string|null
184184
*/
185185
protected function utf8Encode(?string $s)
186186
{

Dumper/CliDumper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ protected function dumpKey(Cursor $cursor)
435435
* @param string $value The value being styled
436436
* @param array $attr Optional context information
437437
*
438-
* @return string The value with style decoration
438+
* @return string
439439
*/
440440
protected function style(string $style, string $value, array $attr = [])
441441
{
@@ -511,7 +511,7 @@ protected function style(string $style, string $value, array $attr = [])
511511
}
512512

513513
/**
514-
* @return bool Tells if the current output stream supports ANSI colors or not
514+
* @return bool
515515
*/
516516
protected function supportsColors()
517517
{

Dumper/ContextProvider/ContextProviderInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
interface ContextProviderInterface
2020
{
2121
/**
22-
* @return array|null Context data or null if unable to provide any context
22+
* @return array|null
2323
*/
2424
public function getContext(): ?array;
2525
}

0 commit comments

Comments
 (0)