3v4l.org

run code in 300+ PHP versions simultaneously
<?php $value = 'ver 1.0'; // string if(is_numeric($value)) { $value = (int)$value; if(strpos($value, '.')) { $value = (float)$value; } } var_dump($value);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 14
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 14
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
Branch analysis from position: 14
filename:       /in/kGd6l
function name:  (null)
number of ops:  18
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'ver+1.0'
    5     1        INIT_FCALL                                               'is_numeric'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $2      
          4      > JMPZ                                                     $2, ->14
    6     5    >   CAST                                          4  ~3      !0
          6        ASSIGN                                                   !0, ~3
    7     7        INIT_FCALL                                               'strpos'
          8        SEND_VAR                                                 !0
          9        SEND_VAL                                                 '.'
         10        DO_ICALL                                         $5      
         11      > JMPZ                                                     $5, ->14
    8    12    >   CAST                                          5  ~6      !0
         13        ASSIGN                                                   !0, ~6
   11    14    >   INIT_FCALL                                               'var_dump'
         15        SEND_VAR                                                 !0
         16        DO_ICALL                                                 
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
196.52 ms | 1395 KiB | 19 Q