3v4l.org

run code in 300+ PHP versions simultaneously
<?php $name = "HelloWorld"; if (strlen($name)<2 || strlen($name)>40 || !ctype_alpha($name)) { $output = json_encode(array('type' => 'error', 'text' => 'Your name seems to be invalid')); } else { $output = json_encode(array('type' => 'success', 'text' => 'OK')); } var_dump($output);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 4, Position 2 = 7
Branch analysis from position: 4
2 jumps found. (Code = 47) Position 1 = 8, Position 2 = 13
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 19
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 23
Branch analysis from position: 23
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
Branch analysis from position: 7
filename:       /in/1oAXJ
function name:  (null)
number of ops:  27
compiled vars:  !0 = $name, !1 = $output
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'HelloWorld'
    3     1        STRLEN                                           ~3      !0
          2        IS_SMALLER                                       ~4      ~3, 2
          3      > JMPNZ_EX                                         ~4      ~4, ->7
          4    >   STRLEN                                           ~5      !0
          5        IS_SMALLER                                       ~6      40, ~5
          6        BOOL                                             ~4      ~6
          7    > > JMPNZ_EX                                         ~4      ~4, ->13
          8    >   INIT_FCALL                                               'ctype_alpha'
          9        SEND_VAR                                                 !0
         10        DO_ICALL                                         $7      
         11        BOOL_NOT                                         ~8      $7
         12        BOOL                                             ~4      ~8
         13    > > JMPZ                                                     ~4, ->19
    4    14    >   INIT_FCALL                                               'json_encode'
         15        SEND_VAL                                                 <array>
         16        DO_ICALL                                         $9      
         17        ASSIGN                                                   !1, $9
    3    18      > JMP                                                      ->23
    6    19    >   INIT_FCALL                                               'json_encode'
         20        SEND_VAL                                                 <array>
         21        DO_ICALL                                         $11     
         22        ASSIGN                                                   !1, $11
    8    23    >   INIT_FCALL                                               'var_dump'
         24        SEND_VAR                                                 !1
         25        DO_ICALL                                                 
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.62 ms | 1013 KiB | 16 Q