3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { protected $id; public function __call($name, $arguments) { $pattern = '/^set([A-Za-z0-9]+)/'; if (preg_match($pattern, $name)) var_dump($arguments); } } $test = new Test; $test->setId(25);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tF4cX
function name:  (null)
number of ops:  7
compiled vars:  !0 = $test
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   NEW                                              $1      'Test'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   16     3        INIT_METHOD_CALL                                         !0, 'setId'
          4        SEND_VAL_EX                                              25
          5        DO_FCALL                                      0          
          6      > RETURN                                                   1

Class Test:
Function __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 11
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
filename:       /in/tF4cX
function name:  __call
number of ops:  12
compiled vars:  !0 = $name, !1 = $arguments, !2 = $pattern
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    9     2        ASSIGN                                                   !2, '%2F%5Eset%28%5BA-Za-z0-9%5D%2B%29%2F'
   10     3        INIT_FCALL                                               'preg_match'
          4        SEND_VAR                                                 !2
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $4      
          7      > JMPZ                                                     $4, ->11
   11     8    >   INIT_FCALL                                               'var_dump'
          9        SEND_VAR                                                 !1
         10        DO_ICALL                                                 
   12    11    > > RETURN                                                   null

End of function __call

End of class Test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.96 ms | 1386 KiB | 17 Q