3v4l.org

run code in 500+ PHP versions simultaneously
<?php error_reporting(E_ALL); $regex = '/^\d+(?:(?:,\d+)+|:\d+)$/'; echo "range 1 - 8192\n"; var_dump(preg_match($regex, implode(',', range(1, 8192)))); var_dump(preg_last_error_msg()); echo "range 1 - 8193\n"; var_dump(preg_match($regex, implode(',', range(1, 8193)))); var_dump(preg_last_error_msg());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/66PlR
function name:  (null)
number of ops:  35
compiled vars:  !0 = $regex
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                                   'error_reporting'
          1        SEND_VAL                                                     30719
          2        DO_ICALL                                                     
    5     3        ASSIGN                                                       !0, '%2F%5E%5Cd%2B%28%3F%3A%28%3F%3A%2C%5Cd%2B%29%2B%7C%3A%5Cd%2B%29%24%2F'
    8     4        ECHO                                                         'range+1+-+8192%0A'
    9     5        INIT_FCALL                                                   'var_dump'
          6        INIT_FCALL                                                   'range'
          7        SEND_VAL                                                     1
          8        SEND_VAL                                                     8192
          9        DO_ICALL                                             $3      
         10        FRAMELESS_ICALL_2                implode             ~4      '%2C', $3
         11        FRAMELESS_ICALL_2                preg_match          ~5      !0, ~4
         12        SEND_VAL                                                     ~5
         13        DO_ICALL                                                     
   10    14        INIT_FCALL                                                   'var_dump'
         15        INIT_FCALL                                                   'preg_last_error_msg'
         16        DO_ICALL                                             $7      
         17        SEND_VAR                                                     $7
         18        DO_ICALL                                                     
   12    19        ECHO                                                         'range+1+-+8193%0A'
   13    20        INIT_FCALL                                                   'var_dump'
         21        INIT_FCALL                                                   'range'
         22        SEND_VAL                                                     1
         23        SEND_VAL                                                     8193
         24        DO_ICALL                                             $9      
         25        FRAMELESS_ICALL_2                implode             ~10     '%2C', $9
         26        FRAMELESS_ICALL_2                preg_match          ~11     !0, ~10
         27        SEND_VAL                                                     ~11
         28        DO_ICALL                                                     
   14    29        INIT_FCALL                                                   'var_dump'
         30        INIT_FCALL                                                   'preg_last_error_msg'
         31        DO_ICALL                                             $13     
         32        SEND_VAR                                                     $13
         33        DO_ICALL                                                     
         34      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
132.2 ms | 483 KiB | 11 Q