3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $array = array ('backtrace', 'print'); array_walk($array, 'walk_callback', str_repeat("\0",4096)); function walk_callback($value, $key, $userdata) { if ($value == 'print') { print($userdata); exit("\n\n"); } elseif ($value == 'backtrace') { debug_backtrace(); if ($userdata !== str_repeat("\0",4096)) { die("won't get here, \$userdata is still clean until we return"); } } }
Output for 4.3.0 - 5.1.6, 5.2.14 - 5.2.17, 5.3.3 - 5.6.23, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Output for 5.3.2
10QXY1��X�PX�PX�XuX`-qQY�QX�X1QXvXPuXY1�vX�zX�zX�PX�uX`-qQY�vX�PX�zX1Q 11(vX8W;Y1 PX?X?X0PX�vX`-qQY�?X0PXIQpVX aI��r�Rck/i�wX�+X(+Xarray9ahzXs0q�0q�Zo�9����j�$AB�q�$A�� s0q3�1q\!�walk_callback!!value�xX�!�xX�?8"S�zXNy�|p{X�}���w9�!9value�zX!!key�zXa! {X8vX�PXfunction!akey@{X!!userdata{X�!�zXP{X|X!�userdata|X!!lback!!printH|X!!backtraceX!! n|XI!,X����!I}Xlack!!(|XUrace!!debug_backtrace!!str_repeat!!p}XQ!won't get here, $userdata is still clean until we returnQ
Output for 5.3.1
1�x�Y1H��8x�8x�X��`����pQYy�X��1Q������Y1؝�@��@���w�8����pQY0���w�@��1Q 11x��8��Y1pw�Xf�Xf��w�@����pQY�f��w�IQ�}� aI��r�Rck/i��(S�xR�array9a���s�ÿ��ÿ8�n�9����jpP�B�qqpP��(*� s�ÿ3��ÿ\!�walk_callback!!value���!���?8"S ��Ny�|����}���w9�!9value��!!key��a! X������w�function!akey���!!userdata���!�����h��!�userdata��!!lback!!print���!!backtrace�!! n��I!XS�����!I`��lack!!x��Urace!!debug_backtrace!!str_repeat!!���Q!won't get here, $userdata is still clean until we returnQ
Output for 5.3.0
1���Y1x2h�h��2��lpQY8��21Q��Y1pp�h�lpQY`�p1Q 11�8�Y1��������p�lpQY���IQ� �aI��r�Rck/i X���array9a�s��l����l�H�n�9����j��B^6q��$I�� s��l�3���l�\!�walk_callback!!value8�!H�?8"SPNy�|��}���w9�!9value !!key@a! ���function!akey�!!userdata�!0�� !�userdata !!lback!!print� !!backtrace!! n!I!������!I�!lack!!� Urace!!debug_backtrace!!str_repeat!!�!Q!won't get here, $userdata is still clean until we returnQ
Output for 5.2.13
)a�e'Y)h�'�e'�e'x�'�'��lQYXf'x�'AQ`�aA��r�Rck/i��'8@'h?'array9aP�'�����9j��� �9*�����Fl��� �9*��k���!�value��'�!��'�?8"S��'Ny�|X�'�}���w9�!9value��'!!key��'a!�}���w �'�v'��'��'userdata!akey(�'!!userdata�'�!��'8�'�'!�userdata�'!!print�'!! n�'!!backtrace'I!��'����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!�'Q!won't get here, $userdata is still clean until we return1QH 'X 'a1xg' �'�g'�'�g'functionYa��'А'А'��'��'��lQY�Q'(�'��'YQ�e'�'8@'(�'YY��'@�'�v'��'А')Y��')
Output for 5.2.12
)aإY)h�����x���lQYX�x�AQ`��aA��r�Rck/i��8�harray9aP����l��9j��l� �y������(l��l� �y��k��l�!�value���!���?8"S��Ny�|X��}���w9�!9value��!!key��a!�}���w ��ض����userdata!akey(�!!userdata��!��8��!�userdata�!!print�!! n�!!backtraceI!������!Iwalk_callbacke!!debug_backtrace!!str_repeat!!�Q!won't get here, $userdata is still clean until we return1QH`X`a1x� ������functionYa�����������lQY��(���YQ����8�(�YY��@�������)Y��)
Output for 5.2.11
)aHD�Y)؀�D�D���pg���lQY�D���AQ`��aA��r�Rck/ih�����array9a�j���T���9j�T�� #������� l�T�� 0�!�k�R��!�valuei��! i��?8"S(k�Ny�|�k��}���w9�!9value�j�!!keyk�a!�}���w `k�HU�0f�0f�userdata!akey�k�!!userdatak��!k��k�pl�!�userdatal�!!print�l�!! nl�!!backtrace�I!n�����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!�m�Q!won't get here, $userdata is still clean until we return1Q�����a1�E� Pn�XF�����E�functionYa ��@o�@o�0���n���lQY00��o�0��YQ�C�Xo����o�YY0o��o�U�0��@o�)Yp�)
Output for 5.2.10
)a(�SY)�T��S��S�TP�S��lQY��S�TAQ`<aA��r�Rck/i��S��S��Sarray9a��S�К�P��9jؚ�P� �V������%lؚ�P� �V�kƘ�P�!�value�S�!�S�?8"S�SNy�|��S�}���w9�!9value�S!!key��Sa!�}���w @�S(�S�S�Suserdata!akeyx�S!!userdata�S�!�S��SP�S!�userdata�S!!print`�S!! n�S!!backtraceSI!�S����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!h�SQ!won't get here, $userdata is still clean until we return1Q��S��Sa1��S 0�S8�ShT��SfunctionYaT �S �ST�S��lQY�Sx�STYQ��S8�S��Sx�SYY�S��S��ST �S)Y��S)
Output for 5.2.9
)a�Q]Y)��]�Q]�Q]��]�t]P�lQYHR]��]AQ`�EaA��r�Rck/i�u](,]+]array9a@x]���ڢ��9j��ڢ� �%`�����&l��ڢ� �%`��k��ڢ�!�value�v]�!�v]�?8"S�x]Ny�|Hy]�}���w9�!9valuexx]!!key�x]a!�}���w �x]�b]�s]�s]userdata!akeyy]!!userdatay]�!�x](y]�y]!�userdatay]!!printz]!! nz]1!!1backtrace]I!�{]����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!8{]Q!won't get here, $userdata is still clean until we return1Q@z]Pz]a1hS] |]�S]8�]xS]functionYaЍ]�|]�|]�]�|]P�lQY�=]H}]�]YQpQ]}](,]H}]YY�|]`}]�b]�]�|])Y�}])
Output for 5.2.8
)a� �Y)�]�� �� ��]�D��lQYX!��]�AQ`e�aA��r�Rck/i�D�8����array9aPG��P�!)��9jX�!)� ��������� lX�!)� �����kF�!)�!�value�E��!�E��?8"S�G�Ny�|XH��}���w9�!9value�G�!!key�G�a!�}���w �G��1��B��B�userdata!akey(H�!!userdataH��!�G�8H�I�!�userdataH�!!printI�!! nI�1!!1backtrace�I!�J�����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!HJ�Q!won't get here, $userdata is still clean until we return1QPI�`I�a1x"� K��"�H]��"�functionYa�\�L�L��\��K��lQY� �XL��\�YQ� �L�8��XL�YY�K�pL��1��\�L�)Y�L�)
Output for 5.2.7
)aؐmY)��m��m��m��m�m�lQYX�m��mAQ`�UaA��r�Rck/i��m8kmjmarray9aP�m�0�����9j8���� �dp����� l8���� �dp��k&����!�value��m�!��m�?8"S��mNy�|X�m�}���w9�!9value��m!!key��ma!�}���w �mءm��m��muserdata!akey(�m!!userdata�m�!��m8�m�m!�userdata�m!!print�m!! n�m1!!1backtracemI!Ⱥm����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!H�mQ!won't get here, $userdata is still clean until we return1QP�m`�ma1x�m �m�mH�m��mfunctionYa��m�m�m��m��m�lQY�|mX�m��mYQ��m�m8kmX�mYY�mp�m��m��m�m)Yؼm)
Output for 5.2.6
)a��Y)������������0����lQY������AQ`��aA��r�Rck/i���h����array9a������U|��9j��U|� �{������&�k��U|� �{�I�kv�U|�!�value����!����?8"S���Ny�|����}���w9�!9value���!!key���a!�}���w ����������userdata!akeyX��!!userdata���!���h��0��!�userdata��!!print@��!! n��1!!1backtrace�I!�������!Iwalk_callbacke!!debug_backtrace!!str_repeat!!x��Q!won't get here, $userdata is still clean until we return1Q������a1��� @����x�����functionYa��0��0�� �������lQY����� ��YQ���H��h�����YY �������� ��0��)Y��)
Output for 5.2.5
)a9�alY)�u��8��8��u�0\� �lQY�9��u�AQ`��aA��r�Rck/i�\�h��array9a�_���9����9j�9���� � ����V�k�9��� � ��k�7���!�value�]��!�]��?8"S�_�Ny�|�`��}���w9�!9value�_�!!key�_�a!�}���w `�J��Z��Z�userdata!akeyX`�!!userdata`��!�_�h`�0a�!�userdataa�!!print@a�!! na�1!!1backtrace�I!�b�����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!xb�Q!won't get here, $userdata is still clean until we return1Q�a��a�a1�:� @c�;�xu��:�functionYau�0d�0d� u��c� �lQY�$��d� u�YQ�8�Hd�h��d�YY d��d��I� u�0d�)Ye�)
Output for 5.2.4
)a��FalY)��F��F��F�F �FpUlQYx�F�FAQX/aA��r�Rck/i��FX�F��Farray9ap�F��Ƃ��9j��Ƃ�s�Is�I������k��Ƃ� ��I�Sk�Ƃ�!�value��F�!��F�?8"S��FNy�|x�F�}���w9�!9value��F!!key��Fa!�}���w �F��F��F��Fuserdata!akeyH�F!!userdata�F�!��FX�F �F!�userdata�F!!print0�F!! n�F1!!1backtraceFI!��F����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!h�FQ!won't get here, $userdata is still clean until we return1Qp�F��Fa1��F 0�F�Fh�F��FfunctionYa�F �F �F�F��FpUlQY�Fx�F�FYQ��F8�FX�Fx�FYY�F��F��F�F �F)Y��F)
Output for 5.2.3
)a1 �Y)�m �0 �0 �m @T lQY�1 �m AQX��aA��r�Rck/i�T x  array9a�W ��3��9j��3�� � ����Vkk��3� � \k�3�!�value�U �!�U �?8"S�W Ny�|�X �}���w9�!9value�W !!key�W a!�}���w 0X B S S userdata!akeyhX !!userdataX �!�W xX @Y !�userdataY !!printPY !! nY 1!!1backtrace I![ ����!Iwalk_callbacke!!debug_backtrace!!str_repeat!!�Z Q!won't get here, $userdata is still clean until we return1Q�Y �Y a1�2  P[ (3 �m �2 functionYa m @\ @\ 0m �[ lQY �\ 0m YQ�0 X\ x �\ YY0\ �\ �A 0m @\ )Y] )
Output for 5.2.2
)a(].�))�I.��a)��r�Rck/i�.�G.�;.array9a��.��#]��9�����#]� S51�����qk�#]� `51d#k8@B-v!]�!�value�.�!�.�?8"S �.Ny�|��.�}���w9�!9value�.!!key�.a!�}���w X�.�G.�~.�~.userdata!akey��.!!userdata�.�!�.��.h�.!�userdata�.!!printx�.!! n�.1!!1backtrace.I!0�.����!Iprintatrace!!debug_backtrace!!str_repeat!!��.Q!won't get here, $userdata is still clean until we return1Q��.Ȅ.)1�].P�.a)@^.��.`�.�.P^.P^.line)aP�. a)x�. (�.�.��.��.function)a�J.Y) �.@�.@�.0�.�.�lQYI.��.0�.YQ�\.X�.�G.��.YY0�.��.�m.0�.@�.)Y�.)
Output for 5.2.1
)YX-�y_sp9)�O�llback/in/vE2lU0x2c5053099`R�x�9�ukey�0� �array_intersect_key��!�value����!�P��?8"S�R�Ny�|hS��}���w9�!9value���!!key���a!��r�RS�(>�P �array!akey���!!userdata���!�R�HS�T�!�userdata��!!print���!! n��1!!1backtrace�I!�U��j0� �!Iprintatrace!!debug_backtrace!!str_repeat!!���Q!won't get here, $userdata is still clean until we return1Q`T�pT�a1�,� V�8.��V��V�file)a(.����a)�U��V�hV�W�V�V�line)aXV� a)�V� 0W��V��i��V�function)a��Y)(i�HX�HX�8i��W�`�jQY@��X�8i�YQ-�`X�(>��X�YY8X��X�P>�8i�HX�)Y Y�)
Output for 5.2.0
)Y��Coubl9)8�Cllback/in/vE2lU0x2468cf099��C�����9� �F�F�&�j��� �F6j�xB����c!�value`S,�!�C�?8"S�CNy�|��C�}���w9�!9value`S,!!key`S,a!��r�RH�Cp�C�oCarray!akey`S,!!userdataS,�!�C��CX�C!�userdataS,!!print`S,!! nS,1!!1backtrace,I! �C����!Iprintatrace!!debug_backtrace!!str_repeat!!`S,Q!won't get here, $userdata is still clean until we return1Q��C��Ca1�Ch�C��CغCغCfile)ap�C`S,a)@�C�C��C`�CP�CP�Cline)a��C a)ȺC x�C8�C��CغCfunction)a0CY)p�C��C��C��C@�C�)kQY�}C�C��CYQH�C��Cp�C�CYY��C�C��C��C��C)Yh�C)