3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test_assert($string, $arguments = array()) { // Make sure we don't pass in an empty string. assert('$string !== \'\' && (empty($arguments) || strtr($string, $arguments) !== \'\')'); // Make sure we don't translate unnecessarily. assert('empty($arguments) || strtr($string, $arguments) != implode($arguments)'); } test_assert('@test f', ['@test' => 'test']);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aiOI9
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   INIT_FCALL                                               'test_assert'
          1        SEND_VAL                                                 '%40test+f'
          2        SEND_VAL                                                 <array>
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Function test_assert:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aiOI9
function name:  test_assert
number of ops:  13
compiled vars:  !0 = $string, !1 = $arguments
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      <array>
    5     2        ASSERT_CHECK                                             
          3        INIT_FCALL                                               'assert'
          4        SEND_VAL                                                 '%24string+%21%3D%3D+%27%27+%26%26+%28empty%28%24arguments%29+%7C%7C+strtr%28%24string%2C+%24arguments%29+%21%3D%3D+%27%27%29'
          5        SEND_VAL                                                 'assert%28%27%24string+%21%3D%3D+%5C%27%5C%27+%26%26+%28empty%28%24arguments%29+%7C%7C+strtr%28%24string%2C+%24arguments%29+%21%3D%3D+%5C%27%5C%27%29%27%29'
          6        DO_ICALL                                                 
    7     7        ASSERT_CHECK                                             
          8        INIT_FCALL                                               'assert'
          9        SEND_VAL                                                 'empty%28%24arguments%29+%7C%7C+strtr%28%24string%2C+%24arguments%29+%21%3D+implode%28%24arguments%29'
         10        SEND_VAL                                                 'assert%28%27empty%28%24arguments%29+%7C%7C+strtr%28%24string%2C+%24arguments%29+%21%3D+implode%28%24arguments%29%27%29'
         11        DO_ICALL                                                 
    8    12      > RETURN                                                   null

End of function test_assert

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.7 ms | 1398 KiB | 16 Q