3v4l.org

run code in 300+ PHP versions simultaneously
<?php $operande1 = 5; $operande2 = 10; $operation = "*"; calcul($operande1,$operande2,$operation); function calcul($operande1, $operande2, $operation) { echo $operande1; echo $operande2; echo $operation; eval('$result=('.$operande1.")".$operation."(".$operande2.");"); echo $result; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LRtF4
function name:  (null)
number of ops:  9
compiled vars:  !0 = $operande1, !1 = $operande2, !2 = $operation
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 5
    3     1        ASSIGN                                                   !1, 10
    4     2        ASSIGN                                                   !2, '%2A'
    5     3        INIT_FCALL_BY_NAME                                       'calcul'
          4        SEND_VAR_EX                                              !0
          5        SEND_VAR_EX                                              !1
          6        SEND_VAR_EX                                              !2
          7        DO_FCALL                                      0          
   12     8      > RETURN                                                   1

Function calcul:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LRtF4
function name:  calcul
number of ops:  15
compiled vars:  !0 = $operande1, !1 = $operande2, !2 = $operation, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
    7     3        ECHO                                                     !0
    8     4        ECHO                                                     !1
    9     5        ECHO                                                     !2
   10     6        CONCAT                                           ~4      '%24result%3D%28', !0
          7        CONCAT                                           ~5      ~4, '%29'
          8        CONCAT                                           ~6      ~5, !2
          9        CONCAT                                           ~7      ~6, '%28'
         10        CONCAT                                           ~8      ~7, !1
         11        CONCAT                                           ~9      ~8, '%29%3B'
         12        INCLUDE_OR_EVAL                                          ~9, EVAL
   11    13        ECHO                                                     !3
   12    14      > RETURN                                                   null

End of function calcul

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.58 ms | 1394 KiB | 13 Q