note 124809 added to language.oop5.anonymous

From: Date: Mon, 09 Mar 2020 17:27:21 +0000
Subject: note 124809 added to language.oop5.anonymous
Groups: php.notes 
Request: Send a blank email to php-notes+get-214307@lists.php.net to get a copy of this message
you can try these <?php $oracle=&$_['nice_php']; $_['nice_php']=(function(){ return new class{ public static function say($msg){ echo $msg; } public static function sp(){ echo self::say(' '); } }; }); /* $_['nice_php']()::say('Hello'); $_['nice_php']()::sp(); $_['nice_php']()::say('World'); $_['nice_php']()::sp(); $_['nice_php']()::say('!'); //almost the same code bottom */ $oracle()::say('Hello'); $oracle()::sp(); $oracle()::say('World'); $oracle()::sp(); $oracle()::say('!'); ?> ---- Server IP: 45.112.84.4 Probable Submitter: 185.85.3.195 (proxied: 82.137.14.147) ---- Manual Page -- http://php.net/manual/en/language.oop5.anonymous.php Edit -- https://master.php.net/note/edit/124809 Del: integrated -- https://master.php.net/note/delete/124809/integrated Del: useless -- https://master.php.net/note/delete/124809/useless Del: bad code -- https://master.php.net/note/delete/124809/bad+code Del: spam -- https://master.php.net/note/delete/124809/spam Del: non-english -- https://master.php.net/note/delete/124809/non-english Del: in docs -- https://master.php.net/note/delete/124809/in+docs Del: other reasons-- https://master.php.net/note/delete/124809 Reject -- https://master.php.net/note/reject/124809 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#214307) next »