This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Test on PHP 7.2 and PHP 5.4 | |
* | |
** This gist is to show that in php7.2 objects are much fater than arrays. | |
** | |
** 1: We create an object with 10 million properties | |
** We pass it to a function 99999 times and modify a property | |
** We pass it to a function by reference 99999 times and modify a parameter | |
** |