@@ -99,7 +99,7 @@ |
||
99 | 99 | // in case a named parameter appears multiple times in the format string |
100 | 100 | if ($paramKeys[$paramName] === -1) { |
101 | 101 | // no - it needs a home |
102 | - $messageData[$nextData] =& $args[$paramName]; |
|
102 | + $messageData[$nextData] = & $args[$paramName]; |
|
103 | 103 | $paramKeys[$paramName] = $nextData; |
104 | 104 | $nextData++; |
105 | 105 | } |
@@ -127,7 +127,7 @@ |
||
127 | 127 | } |
128 | 128 | |
129 | 129 | // $data contains an <object, method> pair |
130 | - return "callable<" . get_class($data[0]). "::" . $data[1] . ">"; |
|
130 | + return "callable<" . get_class($data[0]) . "::" . $data[1] . ">"; |
|
131 | 131 | } |
132 | 132 | |
133 | 133 | /** |
@@ -91,8 +91,6 @@ discard block |
||
91 | 91 | /** |
92 | 92 | * get the list of extra types that are valid for this specific object |
93 | 93 | * |
94 | - * @param object $object |
|
95 | - * the object to examine |
|
96 | 94 | * @return string[] |
97 | 95 | * a (possibly empty) list of types for this object |
98 | 96 | */ |
@@ -104,8 +102,6 @@ discard block |
||
104 | 102 | /** |
105 | 103 | * what PHP type is $data? |
106 | 104 | * |
107 | - * @param mixed $data |
|
108 | - * the data to examine |
|
109 | 105 | * @param int $flags |
110 | 106 | * options to change what we put in the return value |
111 | 107 | * @return string |
@@ -121,7 +117,7 @@ discard block |
||
121 | 117 | * |
122 | 118 | * @param mixed $item |
123 | 119 | * the item to examine |
124 | - * @return array |
|
120 | + * @return string[] |
|
125 | 121 | * the list of type(s) that this item can be |
126 | 122 | */ |
127 | 123 | function get_strict_types($item) |
@@ -59,7 +59,7 @@ |
||
59 | 59 | * |
60 | 60 | * @param mixed $item |
61 | 61 | * the item to examine |
62 | - * @return array |
|
62 | + * @return string[] |
|
63 | 63 | * the list of type(s) that this item can be |
64 | 64 | */ |
65 | 65 | public function __invoke($item) |
@@ -49,9 +49,9 @@ discard block |
||
49 | 49 | class GetStrictTypes |
50 | 50 | { |
51 | 51 | private static $dispatchMap = [ |
52 | - 'array' => [ GetArrayTypes::class, 'from' ], |
|
53 | - 'object' => [ GetObjectTypes::class, 'from' ], |
|
54 | - 'string' => [ GetStringTypes::class, 'from' ], |
|
52 | + 'array' => [GetArrayTypes::class, 'from'], |
|
53 | + 'object' => [GetObjectTypes::class, 'from'], |
|
54 | + 'string' => [GetStringTypes::class, 'from'], |
|
55 | 55 | ]; |
56 | 56 | |
57 | 57 | /** |
@@ -84,6 +84,6 @@ discard block |
||
84 | 84 | } |
85 | 85 | |
86 | 86 | // if we get here, then we just return the PHP scalar type |
87 | - return [ $type ]; |
|
87 | + return [$type]; |
|
88 | 88 | } |
89 | 89 | } |
@@ -118,14 +118,14 @@ |
||
118 | 118 | } |
119 | 119 | |
120 | 120 | // if we get here, then $item will coerce to a PHP numeric type :) |
121 | - return [ $retval ]; |
|
121 | + return [$retval]; |
|
122 | 122 | } |
123 | 123 | |
124 | 124 | private static function fromObject($item) |
125 | 125 | { |
126 | 126 | // does this object support being converted to a string? |
127 | 127 | if (method_exists($item, '__toString')) { |
128 | - return [ 'string' ]; |
|
128 | + return ['string']; |
|
129 | 129 | } |
130 | 130 | |
131 | 131 | // no, it does not |