3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'Hello, there!'; if (!strpos($string, 'Hello')) { echo 'Did not detect "Hello" in string (default)' . PHP_EOL; } if (false == strpos($string, 'Hello')) { echo 'Did not detect "Hello" in string (loose equality)' . PHP_EOL; } if (false === strpos($string, 'Hello')) { echo 'Did not detect "Hello" in string (strict equality)' . PHP_EOL; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 8
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 15
Branch analysis from position: 14
2 jumps found. (Code = 43) Position 1 = 21, Position 2 = 22
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 22
Branch analysis from position: 15
Branch analysis from position: 8
filename:       /in/S0eW2
function name:  (null)
number of ops:  23
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'Hello%2C+there%21'
    5     1        INIT_FCALL                                               'strpos'
          2        SEND_VAR                                                 !0
          3        SEND_VAL                                                 'Hello'
          4        DO_ICALL                                         $2      
          5        BOOL_NOT                                         ~3      $2
          6      > JMPZ                                                     ~3, ->8
    6     7    >   ECHO                                                     'Did+not+detect+%22Hello%22+in+string+%28default%29%0A'
    9     8    >   INIT_FCALL                                               'strpos'
          9        SEND_VAR                                                 !0
         10        SEND_VAL                                                 'Hello'
         11        DO_ICALL                                         $4      
         12        BOOL_NOT                                         ~5      $4
         13      > JMPZ                                                     ~5, ->15
   10    14    >   ECHO                                                     'Did+not+detect+%22Hello%22+in+string+%28loose+equality%29%0A'
   13    15    >   INIT_FCALL                                               'strpos'
         16        SEND_VAR                                                 !0
         17        SEND_VAL                                                 'Hello'
         18        DO_ICALL                                         $6      
         19        TYPE_CHECK                                    4          $6
         20      > JMPZ                                                     ~7, ->22
   14    21    >   ECHO                                                     'Did+not+detect+%22Hello%22+in+string+%28strict+equality%29%0A'
   15    22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.72 ms | 1426 KiB | 14 Q