3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface Kubus { public function set_sisi($s); public function luas_kubus(); public function volume_kubus(); } interface Balok { public function luas_balok($p, $l); public function volume_balok($t); } class Hitung implements Kubus, Balok{ public $sisi; public function set_sisi($s) { $this->sisi = $s; return $this; } public function luas_kubus() { echo "Luas Kubus = " . $this->sisi * 2; return $this; } public function volume_kubus() { echo "Volume Kubus = " . $this->sisi * 3; return $this; } public function luas_balok($p, $l) { return; } public function volume_balok($t) { return; } } $hitung = new Hitung; echo $hitung->set_sisi(4)->luas_kubus()->volume_kubus();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  (null)
number of ops:  13
compiled vars:  !0 = $hitung
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   DECLARE_CLASS                                            'hitung'
   37     1        NEW                                              $1      'Hitung'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   38     4        INIT_METHOD_CALL                                         !0, 'set_sisi'
          5        SEND_VAL_EX                                              4
          6        DO_FCALL                                      0  $4      
          7        INIT_METHOD_CALL                                         $4, 'luas_kubus'
          8        DO_FCALL                                      0  $5      
          9        INIT_METHOD_CALL                                         $5, 'volume_kubus'
         10        DO_FCALL                                      0  $6      
         11        ECHO                                                     $6
         12      > RETURN                                                   1

Class Kubus:
Function set_sisi:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  set_sisi
number of ops:  2
compiled vars:  !0 = $s
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function set_sisi

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

End of function luas_kubus

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

End of function volume_kubus

End of class Kubus.

Class Balok:
Function luas_balok:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  luas_balok
number of ops:  3
compiled vars:  !0 = $p, !1 = $l
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2      > RETURN                                                   null

End of function luas_balok

Function volume_balok:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  volume_balok
number of ops:  2
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function volume_balok

End of class Balok.

Class Hitung:
Function set_sisi:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  set_sisi
number of ops:  6
compiled vars:  !0 = $s
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   RECV                                             !0      
   17     1        ASSIGN_OBJ                                               'sisi'
          2        OP_DATA                                                  !0
   18     3        FETCH_THIS                                       ~2      
          4      > RETURN                                                   ~2
   19     5*     > RETURN                                                   null

End of function set_sisi

Function luas_kubus:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  luas_kubus
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   FETCH_OBJ_R                                      ~0      'sisi'
          1        MUL                                              ~1      ~0, 2
          2        CONCAT                                           ~2      'Luas+Kubus+%3D+', ~1
          3        ECHO                                                     ~2
   22     4        FETCH_THIS                                       ~3      
          5      > RETURN                                                   ~3
   23     6*     > RETURN                                                   null

End of function luas_kubus

Function volume_kubus:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  volume_kubus
number of ops:  7
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   26     0  E >   FETCH_OBJ_R                                      ~0      'sisi'
          1        MUL                                              ~1      ~0, 3
          2        CONCAT                                           ~2      'Volume+Kubus+%3D+', ~1
          3        ECHO                                                     ~2
   27     4        FETCH_THIS                                       ~3      
          5      > RETURN                                                   ~3
   28     6*     > RETURN                                                   null

End of function volume_kubus

Function luas_balok:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  luas_balok
number of ops:  4
compiled vars:  !0 = $p, !1 = $l
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   29     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   30     2      > RETURN                                                   null
   31     3*     > RETURN                                                   null

End of function luas_balok

Function volume_balok:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/L1Qbb
function name:  volume_balok
number of ops:  3
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   32     0  E >   RECV                                             !0      
   33     1      > RETURN                                                   null
   34     2*     > RETURN                                                   null

End of function volume_balok

End of class Hitung.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
175.89 ms | 1403 KiB | 13 Q