3v4l.org

run code in 300+ PHP versions simultaneously
<?php function getStatusColor($color){ if ($color == 'warning'){ return "#eea236"; } if ($color == 'info'){ return "#46b8da"; } if ($color == 'error'){ return "#d43f3a"; } if ($color == 'success'){ return "#4BAD4B"; } } echo getStatusColor('info');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SEMhZ
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   INIT_FCALL                                               'getstatuscolor'
          1        SEND_VAL                                                 'info'
          2        DO_FCALL                                      0  $0      
          3        ECHO                                                     $0
          4      > RETURN                                                   1

Function getstatuscolor:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 4
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 10
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 13
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SEMhZ
function name:  getStatusColor
number of ops:  14
compiled vars:  !0 = $color
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    3     1        IS_EQUAL                                                 !0, 'warning'
          2      > JMPZ                                                     ~1, ->4
    4     3    > > RETURN                                                   '%23eea236'
    6     4    >   IS_EQUAL                                                 !0, 'info'
          5      > JMPZ                                                     ~2, ->7
    7     6    > > RETURN                                                   '%2346b8da'
    9     7    >   IS_EQUAL                                                 !0, 'error'
          8      > JMPZ                                                     ~3, ->10
   10     9    > > RETURN                                                   '%23d43f3a'
   12    10    >   IS_EQUAL                                                 !0, 'success'
         11      > JMPZ                                                     ~4, ->13
   13    12    > > RETURN                                                   '%234BAD4B'
   15    13    > > RETURN                                                   null

End of function getstatuscolor

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.51 ms | 1390 KiB | 14 Q