3v4l.org

run code in 300+ PHP versions simultaneously
<?php $list1 = new \SplDoublyLinkedList(); $list1->push(1); $list1->push(2); $list2 = clone $list1; $list2->push(3); $list2->push(4); var_export(iterator_to_array($list1)); var_export(iterator_to_array($list2));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Yl1v9
function name:  (null)
number of ops:  30
compiled vars:  !0 = $list1, !1 = $list2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $2      'SplDoublyLinkedList'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
    5     3        INIT_METHOD_CALL                                         !0, 'push'
          4        SEND_VAL_EX                                              1
          5        DO_FCALL                                      0          
    6     6        INIT_METHOD_CALL                                         !0, 'push'
          7        SEND_VAL_EX                                              2
          8        DO_FCALL                                      0          
    8     9        CLONE                                            ~7      !0
         10        ASSIGN                                                   !1, ~7
    9    11        INIT_METHOD_CALL                                         !1, 'push'
         12        SEND_VAL_EX                                              3
         13        DO_FCALL                                      0          
   10    14        INIT_METHOD_CALL                                         !1, 'push'
         15        SEND_VAL_EX                                              4
         16        DO_FCALL                                      0          
   12    17        INIT_FCALL                                               'var_export'
         18        INIT_FCALL                                               'iterator_to_array'
         19        SEND_VAR                                                 !0
         20        DO_ICALL                                         $11     
         21        SEND_VAR                                                 $11
         22        DO_ICALL                                                 
   13    23        INIT_FCALL                                               'var_export'
         24        INIT_FCALL                                               'iterator_to_array'
         25        SEND_VAR                                                 !1
         26        DO_ICALL                                         $13     
         27        SEND_VAR                                                 $13
         28        DO_ICALL                                                 
         29      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
195.85 ms | 1395 KiB | 17 Q