Lucas_Werkmeister_WMDE added a comment.

  It’s also curious that “Cannot pass parameter 1 by reference” is not the 
standard error message for calling a reference-parameter function with a 
non-referenceable argument, as far as I can tell. So far I’ve only managed to 
make PHP print that message with a lambda:
  
    lucaswerkmeister-wmde@mw1281:~$ php --version
    PHP 7.2.31-1+0~20200514.41+debian9~1.gbpe2a56b+wmf1+icu63 (cli) (built: Oct 
12 2020 09:43:06) ( NTS )
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
        with Zend OPcache 
v7.2.31-1+0~20200514.41+debian9~1.gbpe2a56b+wmf1+icu63, Copyright (c) 
1999-2018, by Zend Technologies
    lucaswerkmeister-wmde@mw1281:~$ php -a
    Interactive mode enabled
    
    php > explode( ':', 'a:b:c' );
    php > function f( &$ref ) {}
    php > f( ':' );
    Fatal error: Only variables can be passed by reference in php shell code on 
line 1
    php > ('f')( ':' );
    Fatal error: Only variables can be passed by reference in php shell code on 
line 1
    php > $l = function ( &$ref ) {};
    php > $l( ':' );
    Warning: Uncaught Error: Cannot pass parameter 1 by reference in php shell 
code:1
    Stack trace:
    #0 {main}
      thrown in php shell code on line 1
  
  I’m not sure if that’s significant.

TASK DETAIL
  https://phabricator.wikimedia.org/T269315

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: Ladsgroup, mmodell, RhinosF1, Aklapper, Reedy, Akuckartz, Iflorez, 
darthmon_wmde, alaa_wmde, Nandana, Lahi, Gq86, GoranSMilovanovic, QZanden, 
LawExplorer, _jensen, rosalieper, Scott_WUaS, Jonas, Verdy_p, Wikidata-bugs, 
aude, Lydia_Pintscher, Jdforrester-WMF, Mbch331, Rxy, Jay8g
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to