3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Person { public $myAge; public $myName; public $gender; public function __construct($myName, $myAge, $gender) { $this->firstname = $myName; $this->leeftijd = $myAge; $this->geslacht = $gender; } public function greet() { return "Hello my name is ".$this->firstname ."My age is ".$this->leeftijd ."dude!!!".geslacht; } } $me = new Person('martin', 28, 'man'); $me->greet(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/XafiC
function name:  (null)
number of ops:  9
compiled vars:  !0 = $me
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   NEW                                              $1      'Person'
          1        SEND_VAL_EX                                              'martin'
          2        SEND_VAL_EX                                              28
          3        SEND_VAL_EX                                              'man'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !0, $1
   19     6        INIT_METHOD_CALL                                         !0, 'greet'
          7        DO_FCALL                                      0          
   22     8      > RETURN                                                   1

Class Person:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/XafiC
function name:  __construct
number of ops:  10
compiled vars:  !0 = $myName, !1 = $myAge, !2 = $gender
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
    8     3        ASSIGN_OBJ                                               'firstname'
          4        OP_DATA                                                  !0
    9     5        ASSIGN_OBJ                                               'leeftijd'
          6        OP_DATA                                                  !1
   10     7        ASSIGN_OBJ                                               'geslacht'
          8        OP_DATA                                                  !2
   11     9      > RETURN                                                   null

End of function __construct

Function greet:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/XafiC
function name:  greet
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   FETCH_OBJ_R                                      ~0      'firstname'
          1        CONCAT                                           ~1      'Hello+my+name+is+', ~0
          2        CONCAT                                           ~2      ~1, 'My+age+is+'
          3        FETCH_OBJ_R                                      ~3      'leeftijd'
          4        CONCAT                                           ~4      ~2, ~3
          5        CONCAT                                           ~5      ~4, 'dude%21%21%21'
          6        FETCH_CONSTANT                                   ~6      'geslacht'
          7        CONCAT                                           ~7      ~5, ~6
          8      > RETURN                                                   ~7
   15     9*     > RETURN                                                   null

End of function greet

End of class Person.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
140.23 ms | 1395 KiB | 13 Q