3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Provider { /** * Dynamically handle missing method calls. * * @param string $method * @param array $parameters * @return mixed * * @throws \BadMethodCallException */ public function __call($method, $parameters) { if ($method == 'boot') { return; } throw new BadMethodCallException("Call to undefined method [{$method}]"); } } class ProviderB extends Provider { public function boot(int $x) { return 'yay'; } } class ProviderC extends Provider { } $f = new ProviderB; $f->boot(1, 2, 3); $g = new ProviderC; $g->boot(1, 2, 3);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6RRon
function name:  (null)
number of ops:  17
compiled vars:  !0 = $f, !1 = $g
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   35     0  E >   NEW                                              $2      'ProviderB'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   36     3        INIT_METHOD_CALL                                         !0, 'boot'
          4        SEND_VAL_EX                                              1
          5        SEND_VAL_EX                                              2
          6        SEND_VAL_EX                                              3
          7        DO_FCALL                                      0          
   38     8        NEW                                              $6      'ProviderC'
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !1, $6
   39    11        INIT_METHOD_CALL                                         !1, 'boot'
         12        SEND_VAL_EX                                              1
         13        SEND_VAL_EX                                              2
         14        SEND_VAL_EX                                              3
         15        DO_FCALL                                      0          
         16      > RETURN                                                   1

Class Provider:
Function __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 5
Branch analysis from position: 4
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/6RRon
function name:  __call
number of ops:  13
compiled vars:  !0 = $method, !1 = $parameters
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   16     2        IS_EQUAL                                                 !0, 'boot'
          3      > JMPZ                                                     ~2, ->5
   17     4    > > RETURN                                                   null
   19     5    >   NEW                                              $3      'BadMethodCallException'
          6        ROPE_INIT                                     3  ~5      'Call+to+undefined+method+%5B'
          7        ROPE_ADD                                      1  ~5      ~5, !0
          8        ROPE_END                                      2  ~4      ~5, '%5D'
          9        SEND_VAL_EX                                              ~4
         10        DO_FCALL                                      0          
         11      > THROW                                         0          $3
   20    12*     > RETURN                                                   null

End of function __call

End of class Provider.

Class ProviderB:
Function boot:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6RRon
function name:  boot
number of ops:  3
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   25     0  E >   RECV                                             !0      
   27     1      > RETURN                                                   'yay'
   28     2*     > RETURN                                                   null

End of function boot

Function __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 5
Branch analysis from position: 4
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/6RRon
function name:  __call
number of ops:  13
compiled vars:  !0 = $method, !1 = $parameters
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   16     2        IS_EQUAL                                                 !0, 'boot'
          3      > JMPZ                                                     ~2, ->5
   17     4    > > RETURN                                                   null
   19     5    >   NEW                                              $3      'BadMethodCallException'
          6        ROPE_INIT                                     3  ~5      'Call+to+undefined+method+%5B'
          7        ROPE_ADD                                      1  ~5      ~5, !0
          8        ROPE_END                                      2  ~4      ~5, '%5D'
          9        SEND_VAL_EX                                              ~4
         10        DO_FCALL                                      0          
         11      > THROW                                         0          $3
   20    12*     > RETURN                                                   null

End of function __call

End of class ProviderB.

Class ProviderC:
Function __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 5
Branch analysis from position: 4
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/6RRon
function name:  __call
number of ops:  13
compiled vars:  !0 = $method, !1 = $parameters
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   16     2        IS_EQUAL                                                 !0, 'boot'
          3      > JMPZ                                                     ~2, ->5
   17     4    > > RETURN                                                   null
   19     5    >   NEW                                              $3      'BadMethodCallException'
          6        ROPE_INIT                                     3  ~5      'Call+to+undefined+method+%5B'
          7        ROPE_ADD                                      1  ~5      ~5, !0
          8        ROPE_END                                      2  ~4      ~5, '%5D'
          9        SEND_VAL_EX                                              ~4
         10        DO_FCALL                                      0          
         11      > THROW                                         0          $3
   20    12*     > RETURN                                                   null

End of function __call

End of class ProviderC.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.8 ms | 1390 KiB | 13 Q