Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:1952 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 38357 invoked from network); 23 May 2003 21:59:23 -0000 Received: from unknown (HELO localhost.localdomain) (24.60.162.231) by pb1.pair.com with SMTP; 23 May 2003 21:59:23 -0000 Received: (from andrei@localhost) by localhost.localdomain (8.11.6/8.11.6) id h4NLvTX01857; Fri, 23 May 2003 17:57:29 -0400 X-Authentication-Warning: localhost.localdomain: andrei set sender to andrei@gravitonic.com using -f Date: Fri, 23 May 2003 17:57:29 -0400 To: Morten Poulsen Cc: Per Lundberg , PHP Internals List Message-ID: <20030523215728.GC1758@hyperion.gravitonic.com> Mail-Followup-To: Andrei Zmievski , Morten Poulsen , Per Lundberg , PHP Internals List References: <1053704626.1035.21.camel@localhost.localdomain> <1053705633.1279.41.camel@salem.intra.nobolt.net> <1053726799.493.12.camel@marvin> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1053726799.493.12.camel@marvin> User-Agent: Mutt/1.4.1i Subject: Re: [PHP-DEV] [PATCH] make "Call to a member function on a non-object" non-fatal From: andrei@gravitonic.com (Andrei Zmievski) On Fri, 23 May 2003, Morten Poulsen wrote: > The patch might not be the right way to implement it. Calling a member > function on null happens from time to time, when programmers don't check > the return value of a library call. In a production environment it is > bad, not having the option to handle the error, therefore it is bad to > just die. Throwing an exception might be a nicer way, but isn't that > future? Calling a member function on a null should not even happen in production environment, if you architecture your application properly. -Andrei "The most exciting phrase to hear in science, the one that heralds new discoveries, is not "Eureka!" but "That's funny..." -- Isaac Asimov.