3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(0); class foo { function bar() { echo "this is " . (is_null($this) ? 'not ' : '') . "null\n"; } } foo::bar(); (new foo)->bar();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Qn8Pg
function name:  (null)
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 0
          2        DO_ICALL                                                 
   10     3        INIT_STATIC_METHOD_CALL                                  'foo', 'bar'
          4        DO_FCALL                                      0          
   11     5        NEW                                              $2      'foo'
          6        DO_FCALL                                      0          
          7        INIT_METHOD_CALL                                         $2, 'bar'
          8        DO_FCALL                                      0          
          9      > RETURN                                                   1

Class foo:
Function bar:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 5
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Qn8Pg
function name:  bar
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   FETCH_THIS                                       ~0      
          1        TYPE_CHECK                                    2          ~0
          2      > JMPZ                                                     ~1, ->5
          3    >   QM_ASSIGN                                        ~2      'not+'
          4      > JMP                                                      ->6
          5    >   QM_ASSIGN                                        ~2      ''
          6    >   CONCAT                                           ~3      'this+is+', ~2
          7        CONCAT                                           ~4      ~3, 'null%0A'
          8        ECHO                                                     ~4
    7     9      > RETURN                                                   null

End of function bar

End of class foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
196.04 ms | 1395 KiB | 15 Q