3v4l.org

run code in 300+ PHP versions simultaneously
<?php $intColumnValue = 5; $stringColumnValue = "asds"; $stringColumnValueWithQuotes = "asds \"test\" sdfg"; $jsonValue = [ 'number' => 7.8, 'string' => 'aqsdsdw', 'bool' => true, 'stringWithQuotes' => 'test1 "test2" test3', ]; $jsonColumnValue = json_encode($jsonValue); $csvRow = [$intColumnValue, $stringColumnValue, $stringColumnValueWithQuotes, $jsonColumnValue]; fputcsv(STDOUT, $csvRow);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/i4upp
function name:  (null)
number of ops:  19
compiled vars:  !0 = $intColumnValue, !1 = $stringColumnValue, !2 = $stringColumnValueWithQuotes, !3 = $jsonValue, !4 = $jsonColumnValue, !5 = $csvRow
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 5
    4     1        ASSIGN                                                   !1, 'asds'
    5     2        ASSIGN                                                   !2, 'asds+%22test%22+sdfg'
    6     3        ASSIGN                                                   !3, <array>
   12     4        INIT_FCALL                                               'json_encode'
          5        SEND_VAR                                                 !3
          6        DO_ICALL                                         $10     
          7        ASSIGN                                                   !4, $10
   14     8        INIT_ARRAY                                       ~12     !0
          9        ADD_ARRAY_ELEMENT                                ~12     !1
         10        ADD_ARRAY_ELEMENT                                ~12     !2
         11        ADD_ARRAY_ELEMENT                                ~12     !4
         12        ASSIGN                                                   !5, ~12
   16    13        INIT_FCALL                                               'fputcsv'
         14        FETCH_CONSTANT                                   ~14     'STDOUT'
         15        SEND_VAL                                                 ~14
         16        SEND_VAR                                                 !5
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
171.72 ms | 1395 KiB | 17 Q