1--TEST-- 2Uninitialized PDO objects 3--EXTENSIONS-- 4pdo 5--FILE-- 6<?php 7 8class MyPDO extends PDO { 9 public function __construct() {} 10} 11class MyPDOStatement extends PDOStatement { 12 public function __construct() {} 13} 14 15$pdo = new MyPDO; 16try { 17 $pdo->query("foo"); 18} catch (Error $e) { 19 echo $e->getMessage(), "\n"; 20} 21 22$stmt = new MyPDOStatement; 23try { 24 $stmt->fetch(); 25} catch (Error $e) { 26 echo $e->getMessage(), "\n"; 27} 28$stmt = new MyPDOStatement; 29try { 30 foreach ($stmt as $row) {} 31} catch (Error $e) { 32 echo $e->getMessage(), "\n"; 33} 34 35?> 36--EXPECT-- 37MyPDO object is uninitialized 38MyPDOStatement object is uninitialized 39MyPDOStatement object is uninitialized 40