3v4l.org

run code in 300+ PHP versions simultaneously
<?php function checkVal($val){ return empty($val) ? "" : $val; } $show_insert = array( 'title' => checkVal($show_data['title']), 'thetvdb_id' => checkVal($show_data['tvdbid']) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/43Kq4
function name:  (null)
number of ops:  12
compiled vars:  !0 = $show_insert, !1 = $show_data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_FCALL                                               'checkval'
          1        FETCH_DIM_R                                      ~2      !1, 'title'
          2        SEND_VAL                                                 ~2
          3        DO_FCALL                                      0  $3      
          4        INIT_ARRAY                                       ~4      $3, 'title'
    8     5        INIT_FCALL                                               'checkval'
          6        FETCH_DIM_R                                      ~5      !1, 'tvdbid'
          7        SEND_VAL                                                 ~5
          8        DO_FCALL                                      0  $6      
          9        ADD_ARRAY_ELEMENT                                ~4      $6, 'thetvdb_id'
    6    10        ASSIGN                                                   !0, ~4
    9    11      > RETURN                                                   1

Function checkval:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 5
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/43Kq4
function name:  checkVal
number of ops:  8
compiled vars:  !0 = $val
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    3     1        ISSET_ISEMPTY_CV                                         !0
          2      > JMPZ                                                     ~1, ->5
          3    >   QM_ASSIGN                                        ~2      ''
          4      > JMP                                                      ->6
          5    >   QM_ASSIGN                                        ~2      !0
          6    > > RETURN                                                   ~2
    4     7*     > RETURN                                                   null

End of function checkval

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.69 ms | 1398 KiB | 15 Q