@@ -117,7 +117,7 @@ private function doProcessValue($value, $isRoot = false)
117117 }
118118
119119 if ($ constructor ) {
120- array_unshift ($ this ->methodCalls , array ( $ constructor , $ value ->getArguments ()) );
120+ array_unshift ($ this ->methodCalls , [ $ constructor , $ value ->getArguments ()] );
121121 }
122122
123123 $ this ->methodCalls = $ this ->autowireCalls ($ reflectionClass , $ isRoot );
@@ -309,8 +309,8 @@ private function getAutowiredReference(TypedReference $reference)
309309 */
310310 private function populateAvailableTypes ()
311311 {
312- $ this ->types = array () ;
313- $ this ->ambiguousServiceTypes = array () ;
312+ $ this ->types = [] ;
313+ $ this ->ambiguousServiceTypes = [] ;
314314
315315 foreach ($ this ->container ->getDefinitions () as $ id => $ definition ) {
316316 $ this ->populateAvailableType ($ id , $ definition );
@@ -361,7 +361,7 @@ private function set(string $type, string $id)
361361
362362 // keep an array of all services matching this type
363363 if (!isset ($ this ->ambiguousServiceTypes [$ type ])) {
364- $ this ->ambiguousServiceTypes [$ type ] = array ( $ this ->types [$ type ]) ;
364+ $ this ->ambiguousServiceTypes [$ type ] = [ $ this ->types [$ type ]] ;
365365 unset($ this ->types [$ type ]);
366366 }
367367 $ this ->ambiguousServiceTypes [$ type ][] = $ id ;
@@ -436,7 +436,7 @@ private function createTypeAlternatives(TypedReference $reference)
436436
437437 private function getAliasesSuggestionForType ($ type , $ extraContext = null )
438438 {
439- $ aliases = array () ;
439+ $ aliases = [] ;
440440 foreach (class_parents ($ type ) + class_implements ($ type ) as $ parent ) {
441441 if ($ this ->container ->has ($ parent ) && !$ this ->container ->findDefinition ($ parent )->isAbstract ()) {
442442 $ aliases [] = $ parent ;
0 commit comments