Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:54939 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 35191 invoked from network); 25 Aug 2011 12:54:23 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 Aug 2011 12:54:23 -0000 Authentication-Results: pb1.pair.com header.from=ekneuss@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ekneuss@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.214.42 as permitted sender) X-PHP-List-Original-Sender: ekneuss@gmail.com X-Host-Fingerprint: 209.85.214.42 mail-bw0-f42.google.com Received: from [209.85.214.42] ([209.85.214.42:45175] helo=mail-bw0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 27/86-00227-CF5465E4 for ; Thu, 25 Aug 2011 08:54:21 -0400 Received: by bkd19 with SMTP id 19so1781037bkd.29 for ; Thu, 25 Aug 2011 05:54:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=TC49ZNxAJHJB0sB5WRXwJDRomLvC36ATREc0H1v2IQY=; b=bZfsl19SP7F3vmO/RVgdGfl2mqb3/41JAecg+o29qQiLO+YutIeTtMv7zUBs+EHelA P4Fvz2Q96Pu7v8jhWdjvBhOrSGl+Rpm+DfDzx0bmiPT9S6PA+nrhonji1/BPCU8Du+Pm AbsH4ECOnZbWBsXpwxKnDyV9rQA2KlNhMVOlQ= MIME-Version: 1.0 Received: by 10.204.130.138 with SMTP id t10mr2919008bks.10.1314276857871; Thu, 25 Aug 2011 05:54:17 -0700 (PDT) Sender: ekneuss@gmail.com Received: by 10.204.69.211 with HTTP; Thu, 25 Aug 2011 05:54:17 -0700 (PDT) In-Reply-To: <4E5644BD.8040101@php.net> References: <4E5619ED.40609@php.net> <4E5642F7.9060702@php.net> <4E5644BD.8040101@php.net> Date: Thu, 25 Aug 2011 14:54:17 +0200 X-Google-Sender-Auth: myTvC3hZKvMo5VDJTwY4HJYYq6w Message-ID: To: Sebastian Bergmann Cc: internals@lists.php.net Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] ReflectionClass::newInstanceWithoutConstructor() From: colder@php.net (Etienne Kneuss) Hi, On Thu, Aug 25, 2011 at 14:49, Sebastian Bergmann wrote= : > On 08/25/2011 02:47 PM, Kalle Sommer Nielsen wrote: >> >> Speaking of which, wouldn't it be easier to check all our internal >> classes for such failures and fix them accordingly with this addition >> (Fix the dont-crash-without-calling-constructor)? >> >> We could do like that of above and cast an exception instead of >> E_RECOVERABLE_ERROR (as I believe is being cast now) in 5.4. > > =C2=A0Makes sense to me. There is already some standardized checks for 5.4 that wrap around the get_constructor handler. But it should/could be standardized at the engine level. And those raise exceptions in case they detect a uncalled constructor. > > -- > Sebastian Bergmann =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0Co-Founder and Principal Consultant > http://sebastian-bergmann.de/ =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 http://thePHP.cc/ > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --=20 Etienne Kneuss http://www.colder.ch