3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $constants = get_defined_constants(); print_r(array_intersect_key($constants, array_flip(preg_grep('/^P(?:REG|CRE)_/', array_keys($constants)))));
based on GHPeT
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/YmKrI
function name:  (null)
number of ops:  21
compiled vars:  !0 = $constants
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   2     0  E >   INIT_FCALL                                               'get_defined_constants'
         1        DO_ICALL                                         $1      
         2        ASSIGN                                                   !0, $1
   3     3        INIT_FCALL                                               'print_r'
         4        INIT_FCALL                                               'array_intersect_key'
         5        SEND_VAR                                                 !0
         6        INIT_FCALL                                               'array_flip'
         7        INIT_FCALL                                               'preg_grep'
         8        SEND_VAL                                                 '%2F%5EP%28%3F%3AREG%7CCRE%29_%2F'
         9        INIT_FCALL                                               'array_keys'
        10        SEND_VAR                                                 !0
        11        DO_ICALL                                         $3      
        12        SEND_VAR                                                 $3
        13        DO_ICALL                                         $4      
        14        SEND_VAR                                                 $4
        15        DO_ICALL                                         $5      
        16        SEND_VAR                                                 $5
        17        DO_ICALL                                         $6      
        18        SEND_VAR                                                 $6
        19        DO_ICALL                                                 
        20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.3.0