InvalidPassByReference# Error at levels All Emitted when passing a non-variable to a function that expects a by-ref variable <?php function foo(array &$arr) : void {} foo([0, 1, 2]); Get Psalm news by email News about Psalm, a few emails a month. You can unsubscribe at any time. Email Subscribe I accept the privacy policy