3v4l.org

run code in 300+ PHP versions simultaneously
<?php use PDO; interface Connection { function prepare($statement); } class PDOConnection extends PDO implements Connection { public function __construct($dsn, $user = null, $password = null, array $options = null) { print("on PDOConnection::__construct: '$dsn'\n"); parent::__construct($dsn, $user, $password, $options); $this->setAttribute(PDO::ATTR_STATEMENT_CLASS, array('Doctrine\DBAL\Driver\PDOStatement', array())); $this->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); } } new PDOConnection('sqlite::memory:');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iWODB
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   DECLARE_CLASS                                            'pdoconnection', 'pdo'
   21     1        NEW                                              $0      'PDOConnection'
          2        SEND_VAL_EX                                              'sqlite%3A%3Amemory%3A'
          3        DO_FCALL                                      0          
          4        FREE                                                     $0
          5      > RETURN                                                   1

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

End of function prepare

End of class Connection.

Class PDOConnection:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iWODB
function name:  __construct
number of ops:  23
compiled vars:  !0 = $dsn, !1 = $user, !2 = $password, !3 = $options
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
          1        RECV_INIT                                        !1      null
          2        RECV_INIT                                        !2      null
          3        RECV_INIT                                        !3      null
   13     4        ROPE_INIT                                     3  ~5      'on+PDOConnection%3A%3A__construct%3A+%27'
          5        ROPE_ADD                                      1  ~5      ~5, !0
          6        ROPE_END                                      2  ~4      ~5, '%27%0A'
          7        ECHO                                                     ~4
   14     8        INIT_STATIC_METHOD_CALL                                  
          9        SEND_VAR_EX                                              !0
         10        SEND_VAR_EX                                              !1
         11        SEND_VAR_EX                                              !2
         12        SEND_VAR_EX                                              !3
         13        DO_FCALL                                      0          
   15    14        INIT_METHOD_CALL                                         'setAttribute'
         15        SEND_VAL_EX                                              13
         16        SEND_VAL_EX                                              <array>
         17        DO_FCALL                                      0          
   16    18        INIT_METHOD_CALL                                         'setAttribute'
         19        SEND_VAL_EX                                              3
         20        SEND_VAL_EX                                              2
         21        DO_FCALL                                      0          
   17    22      > RETURN                                                   null

End of function __construct

End of class PDOConnection.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.32 ms | 1395 KiB | 13 Q