3v4l.org

run code in 300+ PHP versions simultaneously
<?php foreach (range(1, 2, 0.1) as $r) { var_dump($r); if ($r === 1.7) echo "ok\n"; if (intval($r * 10) === 17) echo "okish\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 19
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 19
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 13
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 17, Position 2 = 18
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 18
Branch analysis from position: 13
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
filename:       /in/YI9A4
function name:  (null)
number of ops:  21
compiled vars:  !0 = $r
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'range'
          1        SEND_VAL                                                 1
          2        SEND_VAL                                                 2
          3        SEND_VAL                                                 0.1
          4        DO_ICALL                                         $1      
          5      > FE_RESET_R                                       $2      $1, ->19
          6    > > FE_FETCH_R                                               $2, !0, ->19
    4     7    >   INIT_FCALL                                               'var_dump'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                                 
    5    10        IS_IDENTICAL                                             !0, 1.7
         11      > JMPZ                                                     ~4, ->13
    6    12    >   ECHO                                                     'ok%0A'
    7    13    >   MUL                                              ~5      !0, 10
         14        CAST                                          4  ~6      ~5
         15        IS_IDENTICAL                                             ~6, 17
         16      > JMPZ                                                     ~7, ->18
    8    17    >   ECHO                                                     'okish%0A'
    3    18    > > JMP                                                      ->6
         19    >   FE_FREE                                                  $2
    9    20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
10.85 ms | 411 KiB | 7 Q