3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = "this is \n text"; $b = "this is ☭ text"; echo mb_strpos($a, "text", 0, "UTF-8") . PHP_EOL; echo mb_strpos($b, "text", 0, "UTF-8") . PHP_EOL;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rAFqS
function name:  (null)
number of ops:  19
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'this+is+%0A+text'
    4     1        ASSIGN                                                   !1, 'this+is+%E2%98%AD+text'
    5     2        INIT_FCALL                                               'mb_strpos'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 'text'
          5        SEND_VAL                                                 0
          6        SEND_VAL                                                 'UTF-8'
          7        DO_ICALL                                         $4      
          8        CONCAT                                           ~5      $4, '%0A'
          9        ECHO                                                     ~5
    6    10        INIT_FCALL                                               'mb_strpos'
         11        SEND_VAR                                                 !1
         12        SEND_VAL                                                 'text'
         13        SEND_VAL                                                 0
         14        SEND_VAL                                                 'UTF-8'
         15        DO_ICALL                                         $6      
         16        CONCAT                                           ~7      $6, '%0A'
         17        ECHO                                                     ~7
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.41 ms | 1394 KiB | 15 Q