3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Dictionary implements ArrayAccess { function offsetExists($offset) {} function offsetGet($offset) {} function offsetUnset($offset) {} function offsetSet($offset, $value) { if (!is_string($offset)) { throw new InvalidArgumentException(); } } } $Dictionary = new Dictionary(); $Dictionary["12"] = 0xDEADBEEF; // int(12) $str = "12"; $Dictionary[$str] = 0xDEADBEEF; // string(2) "12" ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d4mJW
function name:  (null)
number of ops:  10
compiled vars:  !0 = $Dictionary, !1 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   DECLARE_CLASS                                            'dictionary'
   14     1        NEW                                              $2      'Dictionary'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   15     4        ASSIGN_DIM                                               !0, 12
          5        OP_DATA                                                  3735928559
   17     6        ASSIGN                                                   !1, '12'
   18     7        ASSIGN_DIM                                               !0, !1
          8        OP_DATA                                                  3735928559
   19     9      > RETURN                                                   1

Class Dictionary:
Function offsetexists:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d4mJW
function name:  offsetExists
number of ops:  2
compiled vars:  !0 = $offset
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function offsetexists

Function offsetget:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d4mJW
function name:  offsetGet
number of ops:  2
compiled vars:  !0 = $offset
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function offsetget

Function offsetunset:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d4mJW
function name:  offsetUnset
number of ops:  2
compiled vars:  !0 = $offset
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1      > RETURN                                                   null

End of function offsetunset

Function offsetset:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 8
Branch analysis from position: 5
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d4mJW
function name:  offsetSet
number of ops:  9
compiled vars:  !0 = $offset, !1 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    8     2        TYPE_CHECK                                   64  ~2      !0
          3        BOOL_NOT                                         ~3      ~2
          4      > JMPZ                                                     ~3, ->8
    9     5    >   NEW                                              $4      'InvalidArgumentException'
          6        DO_FCALL                                      0          
          7      > THROW                                         0          $4
   11     8    > > RETURN                                                   null

End of function offsetset

End of class Dictionary.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
171.07 ms | 1399 KiB | 13 Q