3v4l.org

run code in 300+ PHP versions simultaneously
<?php // From https://core.trac.wordpress.org/browser/trunk/wp-admin/includes/list-table.php?rev=15491. class WP_List_Table { /** * Various information about the current table * * @since 3.1.0 * @var array * @access private */ var $_args; /** * Various information needed for displaying the pagination * * @since 3.1.0 * @var array * @access private */ var $_pagination_args = array(); /** * The current screen * * @since 3.1.0 * @var object * @access protected */ var $screen; /** * Cached bulk actions * * @since 3.1.0 * @var array * @access private */ var $_actions; /** * Cached pagination output * * @since 3.1.0 * @var string * @access private */ var $_pagination; /** * Constructor. The child class should call this constructor from it's own constructor * * @param array $args An associative array with information about the current table * @access protected */ function WP_List_Table( $args = array() ) {} } function run_test() { $obj = new WP_List_Table(); echo "\n ***** TEST WP 3.1 CODE ***** \n\n\n"; // __get() echo "** Test get **\n"; echo "Defined property: "; var_dump( $obj->_args ); echo "Dynamic property: "; var_dump( $obj->_dynamic_property ); // __isset() echo "\n\n ** Test `isset()` **\n"; echo "Defined property: "; var_dump( isset( $obj->_args ) ); echo "Dynamic property: "; var_dump( isset( $obj->_dynamic_property ) ); // __set() echo "\n\n ** Test set **\n"; $new_value = array( 'test' ); $obj->_args = $new_value; $obj->_dynamic_property = $new_value; echo "With magic methods: "; var_dump( $obj->_args ); echo "Dynamic property: "; var_dump( $obj->_dynamic_property ); // Unset. unset( $obj->_args ); unset( $obj->_dynamic_property ); echo "\n\n ** Test get after `unset()` **\n"; echo "Defined property: "; var_dump( $obj->_args ); echo "Dynamic property: "; var_dump( $obj->_dynamic_property ); echo "\n\n ** Test `isset()` after `unset()` **\n"; echo "Defined property: "; var_dump( isset( $obj->_args ) ); echo "Dynamic property: "; var_dump( isset( $obj->_dynamic_property ) ); echo "\n\n ** Test set after `unset()` **\n"; $new_value = array( 'test after an unset' ); $obj->_args = $new_value; $obj->_dynamic_property = $new_value; echo "Defined property: "; var_dump( $obj->_args ); echo "Dynamic property: "; var_dump( $obj->_dynamic_property ); echo "\n\n ** Test `isset()` after `unset()` and set **\n"; echo "Defined property: "; var_dump( isset( $obj->_args ) ); echo "Dynamic property: "; var_dump( isset( $obj->_dynamic_property ) ); } run_test();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GBfpi
function name:  (null)
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  122     0  E >   INIT_FCALL                                               'run_test'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   1

Function run_test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GBfpi
function name:  run_test
number of ops:  94
compiled vars:  !0 = $obj, !1 = $new_value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   62     0  E >   NEW                                              $2      'WP_List_Table'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   64     3        ECHO                                                     '%0A+%2A%2A%2A%2A%2A+TEST+WP+3.1+CODE+%2A%2A%2A%2A%2A+%0A%0A%0A'
   67     4        ECHO                                                     '%2A%2A+Test+get+%2A%2A%0A'
   68     5        ECHO                                                     'Defined+property%3A+'
   69     6        INIT_FCALL                                               'var_dump'
          7        FETCH_OBJ_R                                      ~5      !0, '_args'
          8        SEND_VAL                                                 ~5
          9        DO_ICALL                                                 
   70    10        ECHO                                                     'Dynamic+property%3A+'
   71    11        INIT_FCALL                                               'var_dump'
         12        FETCH_OBJ_R                                      ~7      !0, '_dynamic_property'
         13        SEND_VAL                                                 ~7
         14        DO_ICALL                                                 
   74    15        ECHO                                                     '%0A%0A+%2A%2A+Test+%60isset%28%29%60+%2A%2A%0A'
   75    16        ECHO                                                     'Defined+property%3A+'
   76    17        INIT_FCALL                                               'var_dump'
         18        ISSET_ISEMPTY_PROP_OBJ                           ~9      !0, '_args'
         19        SEND_VAL                                                 ~9
         20        DO_ICALL                                                 
   77    21        ECHO                                                     'Dynamic+property%3A+'
   78    22        INIT_FCALL                                               'var_dump'
         23        ISSET_ISEMPTY_PROP_OBJ                           ~11     !0, '_dynamic_property'
         24        SEND_VAL                                                 ~11
         25        DO_ICALL                                                 
   81    26        ECHO                                                     '%0A%0A+%2A%2A+Test+set+%2A%2A%0A'
   82    27        ASSIGN                                                   !1, <array>
   83    28        ASSIGN_OBJ                                               !0, '_args'
         29        OP_DATA                                                  !1
   84    30        ASSIGN_OBJ                                               !0, '_dynamic_property'
         31        OP_DATA                                                  !1
   85    32        ECHO                                                     'With+magic+methods%3A+'
   86    33        INIT_FCALL                                               'var_dump'
         34        FETCH_OBJ_R                                      ~16     !0, '_args'
         35        SEND_VAL                                                 ~16
         36        DO_ICALL                                                 
   87    37        ECHO                                                     'Dynamic+property%3A+'
   88    38        INIT_FCALL                                               'var_dump'
         39        FETCH_OBJ_R                                      ~18     !0, '_dynamic_property'
         40        SEND_VAL                                                 ~18
         41        DO_ICALL                                                 
   91    42        UNSET_OBJ                                                !0, '_args'
   92    43        UNSET_OBJ                                                !0, '_dynamic_property'
   94    44        ECHO                                                     '%0A%0A+%2A%2A+Test+get+after+%60unset%28%29%60+%2A%2A%0A'
   95    45        ECHO                                                     'Defined+property%3A+'
   96    46        INIT_FCALL                                               'var_dump'
         47        FETCH_OBJ_R                                      ~20     !0, '_args'
         48        SEND_VAL                                                 ~20
         49        DO_ICALL                                                 
   97    50        ECHO                                                     'Dynamic+property%3A+'
   98    51        INIT_FCALL                                               'var_dump'
         52        FETCH_OBJ_R                                      ~22     !0, '_dynamic_property'
         53        SEND_VAL                                                 ~22
         54        DO_ICALL                                                 
  100    55        ECHO                                                     '%0A%0A+%2A%2A+Test+%60isset%28%29%60+after+%60unset%28%29%60+%2A%2A%0A'
  101    56        ECHO                                                     'Defined+property%3A+'
  102    57        INIT_FCALL                                               'var_dump'
         58        ISSET_ISEMPTY_PROP_OBJ                           ~24     !0, '_args'
         59        SEND_VAL                                                 ~24
         60        DO_ICALL                                                 
  103    61        ECHO                                                     'Dynamic+property%3A+'
  104    62        INIT_FCALL                                               'var_dump'
         63        ISSET_ISEMPTY_PROP_OBJ                           ~26     !0, '_dynamic_property'
         64        SEND_VAL                                                 ~26
         65        DO_ICALL                                                 
  106    66        ECHO                                                     '%0A%0A+%2A%2A+Test+set+after+%60unset%28%29%60+%2A%2A%0A'
  107    67        ASSIGN                                                   !1, <array>
  108    68        ASSIGN_OBJ                                               !0, '_args'
         69        OP_DATA                                                  !1
  109    70        ASSIGN_OBJ                                               !0, '_dynamic_property'
         71        OP_DATA                                                  !1
  110    72        ECHO                                                     'Defined+property%3A+'
  111    73        INIT_FCALL                                               'var_dump'
         74        FETCH_OBJ_R                                      ~31     !0, '_args'
         75        SEND_VAL                                                 ~31
         76        DO_ICALL                                                 
  112    77        ECHO                                                     'Dynamic+property%3A+'
  113    78        INIT_FCALL                                               'var_dump'
         79        FETCH_OBJ_R                                      ~33     !0, '_dynamic_property'
         80        SEND_VAL                                                 ~33
         81        DO_ICALL                                                 
  115    82        ECHO                                                     '%0A%0A+%2A%2A+Test+%60isset%28%29%60+after+%60unset%28%29%60+and+set+%2A%2A%0A'
  116    83        ECHO                                                     'Defined+property%3A+'
  117    84        INIT_FCALL                                               'var_dump'
         85        ISSET_ISEMPTY_PROP_OBJ                           ~35     !0, '_args'
         86        SEND_VAL                                                 ~35
         87        DO_ICALL                                                 
  118    88        ECHO                                                     'Dynamic+property%3A+'
  119    89        INIT_FCALL                                               'var_dump'
         90        ISSET_ISEMPTY_PROP_OBJ                           ~37     !0, '_dynamic_property'
         91        SEND_VAL                                                 ~37
         92        DO_ICALL                                                 
  120    93      > RETURN                                                   null

End of function run_test

Class WP_List_Table:
Function wp_list_table:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GBfpi
function name:  WP_List_Table
number of ops:  2
compiled vars:  !0 = $args
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   58     0  E >   RECV_INIT                                        !0      <array>
          1      > RETURN                                                   null

End of function wp_list_table

End of class WP_List_Table.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.56 ms | 1448 KiB | 15 Q