3v4l.org

run code in 300+ PHP versions simultaneously
<?php class B { public function __toString() { return 'b'; } } $a = 'a'; $b = new B(); $c = $a . $b; echo $c;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/u3nXl
function name:  (null)
number of ops:  9
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_CLASS                                            'b'
    9     1        ASSIGN                                                   !0, 'a'
   10     2        NEW                                              $4      'B'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !1, $4
   11     5        CONCAT                                           ~7      !0, !1
          6        ASSIGN                                                   !2, ~7
   12     7        ECHO                                                     !2
          8      > RETURN                                                   1

Class B:
Function __tostring:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/u3nXl
function name:  __toString
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E > > RETURN                                                   'b'
    6     1*       VERIFY_RETURN_TYPE                                       
          2*     > RETURN                                                   null

End of function __tostring

End of class B.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.44 ms | 1393 KiB | 13 Q