3v4l.org

run code in 300+ PHP versions simultaneously
<?php class R { public $digit; function __construct($digit) { $this->digit = $digit; } function __destruct() { echo "$digit"; } } function rev($number) { foreach (str_aplit($number) as $digit) { $objs[] = new R($digit); } } rev(13457);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hXUkq
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   INIT_FCALL                                               'rev'
          1        SEND_VAL                                                 13457
          2        DO_FCALL                                      0          
          3      > RETURN                                                   1

Function rev:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
2 jumps found. (Code = 78) Position 1 = 6, Position 2 = 12
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 5
Branch analysis from position: 5
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/hXUkq
function name:  rev
number of ops:  14
compiled vars:  !0 = $number, !1 = $digit, !2 = $objs
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
   10     1        INIT_FCALL_BY_NAME                                       'str_aplit'
          2        SEND_VAR_EX                                              !0
          3        DO_FCALL                                      0  $3      
          4      > FE_RESET_R                                       $4      $3, ->12
          5    > > FE_FETCH_R                                               $4, !1, ->12
   11     6    >   NEW                                              $6      'R'
          7        SEND_VAR_EX                                              !1
          8        DO_FCALL                                      0          
          9        ASSIGN_DIM                                               !2
         10        OP_DATA                                                  $6
   10    11      > JMP                                                      ->5
         12    >   FE_FREE                                                  $4
   13    13      > RETURN                                                   null

End of function rev

Class R:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hXUkq
function name:  __construct
number of ops:  4
compiled vars:  !0 = $digit
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        ASSIGN_OBJ                                               'digit'
          2        OP_DATA                                                  !0
          3      > RETURN                                                   null

End of function __construct

Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hXUkq
function name:  __destruct
number of ops:  3
compiled vars:  !0 = $digit
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   CAST                                          6  ~1      !0
          1        ECHO                                                     ~1
          2      > RETURN                                                   null

End of function __destruct

End of class R.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.47 ms | 1399 KiB | 14 Q