3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array('recursive'); $arr[] = & $arr; var_dump(json_encode($arr)); var_dump(json_last_error()); var_dump(PHP_VERSION_ID >= 50500 ? json_last_error_msg() : NULL);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 16, Position 2 = 20
Branch analysis from position: 16
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LCdJr
function name:  (null)
number of ops:  24
compiled vars:  !0 = $arr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        FETCH_DIM_W                                      $2      !0
          2        ASSIGN_REF                                               $2, !0
    4     3        INIT_FCALL                                               'var_dump'
          4        INIT_FCALL                                               'json_encode'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $4      
          7        SEND_VAR                                                 $4
          8        DO_ICALL                                                 
    5     9        INIT_FCALL                                               'var_dump'
         10        INIT_FCALL                                               'json_last_error'
         11        DO_ICALL                                         $6      
         12        SEND_VAR                                                 $6
         13        DO_ICALL                                                 
    6    14        INIT_FCALL                                               'var_dump'
         15      > JMPZ                                                     <true>, ->20
         16    >   INIT_FCALL                                               'json_last_error_msg'
         17        DO_ICALL                                         $8      
         18        QM_ASSIGN                                        ~9      $8
         19      > JMP                                                      ->21
         20    >   QM_ASSIGN                                        ~9      null
         21    >   SEND_VAL                                                 ~9
         22        DO_ICALL                                                 
         23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.94 ms | 1395 KiB | 21 Q