php-8.0.30-src/ext/pdo/tests/bug_77849_2.phpt

19 lines
361 B
PHP

--TEST--
PDO Common: Bug #77849 (inconsistent state of cloned statament object)
--SKIPIF--
<?php
if (!extension_loaded('pdo')) die('skip');
?>
--FILE--
<?php
$stmt = new PDOStatement();
clone $stmt;
?>
--EXPECTF--
Fatal error: Uncaught Error: Trying to clone an uncloneable object of class PDOStatement in %s:4
Stack trace:
#0 {main}
thrown in %s on line 4