Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:100138 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 26146 invoked from network); 31 Jul 2017 14:54:58 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 Jul 2017 14:54:58 -0000 Authentication-Results: pb1.pair.com smtp.mail=johannes@schlueters.de; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=johannes@schlueters.de; sender-id=unknown Received-SPF: error (pb1.pair.com: domain schlueters.de from 84.19.169.162 cause and error) X-PHP-List-Original-Sender: johannes@schlueters.de X-Host-Fingerprint: 84.19.169.162 mail.experimentalworks.net Received: from [84.19.169.162] ([84.19.169.162:46216] helo=mail.experimentalworks.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id A3/EE-07025-2C44F795 for ; Mon, 31 Jul 2017 10:54:58 -0400 Received: from kuechenschabe.fritz.box (ppp-46-244-166-77.dynamic.mnet-online.de [46.244.166.77]) by mail.experimentalworks.net (Postfix) with ESMTPSA id 58FE65F2C4; Mon, 31 Jul 2017 16:54:54 +0200 (CEST) Message-ID: <1501512881.14647.31.camel@schlueters.de> To: Andrew Nester , Dan Ackroyd Cc: "internals@lists.php.net" Date: Mon, 31 Jul 2017 16:54:41 +0200 In-Reply-To: <2A653728-97CA-4AA5-BA30-5BF26FABBC2A@bk.ru> References: <1907EFF3-ED77-4F5C-85AA-CDFE323369C5@bk.ru> <880CDC06-17D6-4E40-8A48-F2E1CB405667@bk.ru> <2A653728-97CA-4AA5-BA30-5BF26FABBC2A@bk.ru> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.18.5.2-0ubuntu3.2 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: Re: [PHP-DEV] [Request][Discussion] Introduce interfaces PDOInterface and PDOStatementInterface From: johannes@schlueters.de (Johannes =?ISO-8859-1?Q?Schl=FCter?=) On Mo, 2017-07-31 at 14:49 +0300, Andrew Nester wrote: > That’s actually the thing that you can’t use > PDO::ATTR_STATEMENT_CLASS with persistent PDO. The actually question is: Why not? - From a quick glance on the code I see no obvious reason. In speculation I assume the implementor thought "Well, we can't guarantee that a class that is there in one request will be there on the next release and it will quite certainly be at a different memory address thus the cached class_entry pointer will be wrong" but the user has to reset the attribute anyways ... we just have to make sure the different dbh->def_stmt_flags are clean when a new PDO connection object is created recovering an old connection ... johannes