3v4l.org

run code in 300+ PHP versions simultaneously
<?php $localhost = '/^(((localhost|127\.0\.0\.1|\[\:\:1\])(\:[1-9]{1}[0-9]{0,4})?)|(\:\:1))$/'; var_dump(preg_match($localhost, '127.0.0.1:80')); var_dump(preg_match($localhost, '127.0.0.1:80')); var_dump(preg_match($localhost, '127.0.0.1:8000')); var_dump(preg_match($localhost, '127.0.0.1:65535')); var_dump(preg_match($localhost, '127.0.0.1:6553511111111'));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qAagS
function name:  (null)
number of ops:  37
compiled vars:  !0 = $localhost
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%2F%5E%28%28%28localhost%7C127%5C.0%5C.0%5C.1%7C%5C%5B%5C%3A%5C%3A1%5C%5D%29%28%5C%3A%5B1-9%5D%7B1%7D%5B0-9%5D%7B0%2C4%7D%29%3F%29%7C%28%5C%3A%5C%3A1%29%29%24%2F'
    5     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'preg_match'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 '127.0.0.1%3A80'
          5        DO_ICALL                                         $2      
          6        SEND_VAR                                                 $2
          7        DO_ICALL                                                 
    6     8        INIT_FCALL                                               'var_dump'
          9        INIT_FCALL                                               'preg_match'
         10        SEND_VAR                                                 !0
         11        SEND_VAL                                                 '127.0.0.1%3A80'
         12        DO_ICALL                                         $4      
         13        SEND_VAR                                                 $4
         14        DO_ICALL                                                 
    7    15        INIT_FCALL                                               'var_dump'
         16        INIT_FCALL                                               'preg_match'
         17        SEND_VAR                                                 !0
         18        SEND_VAL                                                 '127.0.0.1%3A8000'
         19        DO_ICALL                                         $6      
         20        SEND_VAR                                                 $6
         21        DO_ICALL                                                 
    8    22        INIT_FCALL                                               'var_dump'
         23        INIT_FCALL                                               'preg_match'
         24        SEND_VAR                                                 !0
         25        SEND_VAL                                                 '127.0.0.1%3A65535'
         26        DO_ICALL                                         $8      
         27        SEND_VAR                                                 $8
         28        DO_ICALL                                                 
    9    29        INIT_FCALL                                               'var_dump'
         30        INIT_FCALL                                               'preg_match'
         31        SEND_VAR                                                 !0
         32        SEND_VAL                                                 '127.0.0.1%3A6553511111111'
         33        DO_ICALL                                         $10     
         34        SEND_VAR                                                 $10
         35        DO_ICALL                                                 
         36      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.46 ms | 1000 KiB | 15 Q