3v4l.org

run code in 300+ PHP versions simultaneously
<?php function generator() { yield // this comment doesn't make sense, but hey, why not? /* the blank line above doesn't make sense either, as well as this comment */ /* and thinking about it – */ // why not go batshit crazy with this? /* he */ from gen2(); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4CLhM
function name:  (null)
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E > > RETURN                                                   1

Function generator:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 161) Position 1 = -2
filename:       /in/4CLhM
function name:  generator
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   GENERATOR_CREATE                                         
   11     1        INIT_FCALL_BY_NAME                                       'gen2'
          2        DO_FCALL                                      0  $0      
          3        YIELD_FROM                                       ~1      $0
          4        FREE                                                     ~1
   12     5      > GENERATOR_RETURN                                         

End of function generator

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.83 ms | 1438 KiB | 13 Q