3v4l.org

run code in 300+ PHP versions simultaneously
<?php function andnot($a, $b) { return $a & ~$b; } var_dump(andnot(15, 3)); var_dump(andnot(15, "3")); var_dump(andnot("15", 3)); var_dump(andnot("15", "3"));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sQBZO
function name:  (null)
number of ops:  29
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_FCALL                                               'var_dump'
          1        INIT_FCALL                                               'andnot'
          2        SEND_VAL                                                 15
          3        SEND_VAL                                                 3
          4        DO_FCALL                                      0  $0      
          5        SEND_VAR                                                 $0
          6        DO_ICALL                                                 
    8     7        INIT_FCALL                                               'var_dump'
          8        INIT_FCALL                                               'andnot'
          9        SEND_VAL                                                 15
         10        SEND_VAL                                                 '3'
         11        DO_FCALL                                      0  $2      
         12        SEND_VAR                                                 $2
         13        DO_ICALL                                                 
    9    14        INIT_FCALL                                               'var_dump'
         15        INIT_FCALL                                               'andnot'
         16        SEND_VAL                                                 '15'
         17        SEND_VAL                                                 3
         18        DO_FCALL                                      0  $4      
         19        SEND_VAR                                                 $4
         20        DO_ICALL                                                 
   10    21        INIT_FCALL                                               'var_dump'
         22        INIT_FCALL                                               'andnot'
         23        SEND_VAL                                                 '15'
         24        SEND_VAL                                                 '3'
         25        DO_FCALL                                      0  $6      
         26        SEND_VAR                                                 $6
         27        DO_ICALL                                                 
         28      > RETURN                                                   1

Function andnot:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sQBZO
function name:  andnot
number of ops:  6
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    4     2        BW_NOT                                           ~2      !1
          3        BW_AND                                           ~3      !0, ~2
          4      > RETURN                                                   ~3
    5     5*     > RETURN                                                   null

End of function andnot

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
138.73 ms | 1003 KiB | 18 Q