3v4l.org

run code in 300+ PHP versions simultaneously
<?php ini_set("intl.use_exceptions", true); try{ var_dump(idn_to_ascii( "", IDNA_USE_STD3_RULES | IDNA_NONTRANSITIONAL_TO_ASCII | IDNA_CHECK_CONTEXTJ, INTL_IDNA_VARIANT_UTS46, $info )); }catch(\Throwable $e){ } var_dump($info); $errors = [ "IDNA_ERROR_EMPTY_LABEL", "IDNA_ERROR_LABEL_TOO_LONG", "IDNA_ERROR_DOMAIN_NAME_TOO_LONG", "IDNA_ERROR_LEADING_HYPHEN", "IDNA_ERROR_TRAILING_HYPHEN", "IDNA_ERROR_HYPHEN_3_4", "IDNA_ERROR_LEADING_COMBINING_MARK", "IDNA_ERROR_DISALLOWED", "IDNA_ERROR_PUNYCODE", "IDNA_ERROR_LABEL_HAS_DOT", "IDNA_ERROR_INVALID_ACE_LABEL", "IDNA_ERROR_BIDI", "IDNA_ERROR_CONTEXTJ" ]; foreach($errors as $errorReadable){ $error = constant($errorReadable); if($info['errors'] & $error){ echo $errorReadable . "\n"; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
2 jumps found. (Code = 77) Position 1 = 26, Position 2 = 37
Branch analysis from position: 26
2 jumps found. (Code = 78) Position 1 = 27, Position 2 = 37
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 34, Position 2 = 36
Branch analysis from position: 34
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
Branch analysis from position: 36
Branch analysis from position: 37
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 37
Found catch point at position: 20
Branch analysis from position: 20
2 jumps found. (Code = 107) Position 1 = 21, Position 2 = -2
Branch analysis from position: 21
filename:       /in/VOIWI
function name:  (null)
number of ops:  39
compiled vars:  !0 = $info, !1 = $e, !2 = $errors, !3 = $errorReadable, !4 = $error
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'ini_set'
          1        SEND_VAL                                                 'intl.use_exceptions'
          2        SEND_VAL                                                 <true>
          3        DO_ICALL                                                 
    5     4        INIT_FCALL                                               'var_dump'
          5        INIT_FCALL_BY_NAME                                       'idn_to_ascii'
    6     6        SEND_VAL_EX                                              ''
    7     7        FETCH_CONSTANT                                   ~6      'IDNA_USE_STD3_RULES'
          8        FETCH_CONSTANT                                   ~7      'IDNA_NONTRANSITIONAL_TO_ASCII'
          9        BW_OR                                            ~8      ~6, ~7
         10        FETCH_CONSTANT                                   ~9      'IDNA_CHECK_CONTEXTJ'
         11        BW_OR                                            ~10     ~8, ~9
         12        SEND_VAL_EX                                              ~10
    8    13        FETCH_CONSTANT                                   ~11     'INTL_IDNA_VARIANT_UTS46'
         14        SEND_VAL_EX                                              ~11
    6    15        SEND_VAR_EX                                              !0
         16        DO_FCALL                                      0  $12     
         17        SEND_VAR                                                 $12
         18        DO_ICALL                                                 
         19      > JMP                                                      ->21
   11    20  E > > CATCH                                       last         'Throwable'
   15    21    >   INIT_FCALL                                               'var_dump'
         22        SEND_VAR                                                 !0
         23        DO_ICALL                                                 
   17    24        ASSIGN                                                   !2, <array>
   34    25      > FE_RESET_R                                       $16     !2, ->37
         26    > > FE_FETCH_R                                               $16, !3, ->37
   35    27    >   INIT_FCALL                                               'constant'
         28        SEND_VAR                                                 !3
         29        DO_ICALL                                         $17     
         30        ASSIGN                                                   !4, $17
   36    31        FETCH_DIM_R                                      ~19     !0, 'errors'
         32        BW_AND                                           ~20     !4, ~19
         33      > JMPZ                                                     ~20, ->36
   37    34    >   CONCAT                                           ~21     !3, '%0A'
         35        ECHO                                                     ~21
   34    36    > > JMP                                                      ->26
         37    >   FE_FREE                                                  $16
   39    38      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.47 ms | 1400 KiB | 22 Q