3v4l.org

run code in 300+ PHP versions simultaneously
<?php function pawshake_notification_add($notification_type, $external_id, $uid = 0, $expire = -1, $variables = array()) { $notification = array( 'created' => REQUEST_TIME, 'notification_type' => $notification_type, 'external_id' => $external_id, 'variables' => $variables, ); // User id is optional. if ($uid) { $notification['uid'] = $uid; } // If no expire is send, default to one day. if ($expire == -1) { $notification['expire'] = REQUEST_TIME + 86400; } print_r($notification); } $expire = time() + 86400 + 86400; pawshake_notification_add('thread_start', $message->thread_id, 0, $expire);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dpd2V
function name:  (null)
number of ops:  13
compiled vars:  !0 = $expire, !1 = $message
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   25     0  E >   INIT_FCALL                                               'time'
          1        DO_ICALL                                         $2      
          2        ADD                                              ~3      $2, 86400
          3        ADD                                              ~4      ~3, 86400
          4        ASSIGN                                                   !0, ~4
   26     5        INIT_FCALL                                               'pawshake_notification_add'
          6        SEND_VAL                                                 'thread_start'
          7        FETCH_OBJ_R                                      ~6      !1, 'thread_id'
          8        SEND_VAL                                                 ~6
          9        SEND_VAL                                                 0
         10        SEND_VAR                                                 !0
         11        DO_FCALL                                      0          
         12      > RETURN                                                   1

Function pawshake_notification_add:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 14
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 16, Position 2 = 20
Branch analysis from position: 16
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
Branch analysis from position: 14
filename:       /in/dpd2V
function name:  pawshake_notification_add
number of ops:  24
compiled vars:  !0 = $notification_type, !1 = $external_id, !2 = $uid, !3 = $expire, !4 = $variables, !5 = $notification
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV_INIT                                        !2      0
          3        RECV_INIT                                        !3      -1
          4        RECV_INIT                                        !4      <array>
    6     5        FETCH_CONSTANT                                   ~6      'REQUEST_TIME'
          6        INIT_ARRAY                                       ~7      ~6, 'created'
    7     7        ADD_ARRAY_ELEMENT                                ~7      !0, 'notification_type'
    8     8        ADD_ARRAY_ELEMENT                                ~7      !1, 'external_id'
    9     9        ADD_ARRAY_ELEMENT                                ~7      !4, 'variables'
    5    10        ASSIGN                                                   !5, ~7
   13    11      > JMPZ                                                     !2, ->14
   14    12    >   ASSIGN_DIM                                               !5, 'uid'
         13        OP_DATA                                                  !2
   18    14    >   IS_EQUAL                                                 !3, -1
         15      > JMPZ                                                     ~10, ->20
   19    16    >   FETCH_CONSTANT                                   ~12     'REQUEST_TIME'
         17        ADD                                              ~13     ~12, 86400
         18        ASSIGN_DIM                                               !5, 'expire'
         19        OP_DATA                                                  ~13
   22    20    >   INIT_FCALL                                               'print_r'
         21        SEND_VAR                                                 !5
         22        DO_ICALL                                                 
   23    23      > RETURN                                                   null

End of function pawshake_notification_add

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.1 ms | 1403 KiB | 18 Q