Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:64866 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 54893 invoked from network); 11 Jan 2013 19:17:51 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 11 Jan 2013 19:17:51 -0000 Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 67.192.241.173 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 67.192.241.173 smtp173.dfw.emailsrvr.com Linux 2.6 Received: from [67.192.241.173] ([67.192.241.173:39939] helo=smtp173.dfw.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 8F/94-11723-D5560F05 for ; Fri, 11 Jan 2013 14:17:50 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp7.relay.dfw1a.emailsrvr.com (SMTP Server) with ESMTP id 8581025824E; Fri, 11 Jan 2013 14:17:46 -0500 (EST) X-Virus-Scanned: OK Received: by smtp7.relay.dfw1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id F200B258167; Fri, 11 Jan 2013 14:17:45 -0500 (EST) Message-ID: <50F0654E.6050305@sugarcrm.com> Date: Fri, 11 Jan 2013 11:17:34 -0800 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:17.0) Gecko/20130107 Thunderbird/17.0.2 MIME-Version: 1.0 To: Clint Priest CC: PHP internals References: <50EF2634.9030008@sugarcrm.com> <50EF8FCF.7020701@zerocue.com> <50F03079.3030801@zerocue.com> In-Reply-To: <50F03079.3030801@zerocue.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] A remark about PHP's Vision and new things. From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > A function that is related to a zend_function struct could be placed > anywhere, in any file and can be named in any way. Finding it is like > looking for a needle in a haystack, then you add macros. You can do macros in C++ too, and you can have detached functions too. And it is perfectly possible to make mess with classes, I have seen it many times. Thinking that the language would somehow make you write good code is an illusion. It can help you or fail to help you, but it can never make you. C has tools to help you, though some of them aren't as powerful as I would wish for, it still has them. > When I first started with working with the php-core I was doing > everything wrong because it's a big mess, that's what happens with C, it It has nothing to do with C. Thinking that if PHP core was written in you would instantly get what's going on after 3 minutes looking in the code is, again, an illusion. PHP core is complex, because it does complex things. It also somewhat messy as any organic growth project becomes after 15 years. Nothing has anything to do with the language. You don't need C++ to not put new zend_hash functions into zend_compile.c. You just need common sense and knowledge how the project works. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227