Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:38260 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 73981 invoked from network); 15 Jun 2008 19:12:27 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Jun 2008 19:12:27 -0000 Authentication-Results: pb1.pair.com smtp.mail=chrisstocktonaz@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=chrisstocktonaz@gmail.com; sender-id=pass; domainkeys=bad Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.200.170 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: chrisstocktonaz@gmail.com X-Host-Fingerprint: 209.85.200.170 wf-out-1314.google.com Received: from [209.85.200.170] ([209.85.200.170:18481] helo=wf-out-1314.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C2/4C-06776-B9965584 for ; Sun, 15 Jun 2008 15:12:27 -0400 Received: by wf-out-1314.google.com with SMTP id 26so4766122wfd.26 for ; Sun, 15 Jun 2008 12:12:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type:references; bh=ur0r9GK44PzxFAXnQRksqoIceCSzTPzSZmcO4Tehhq4=; b=kV8h4CuMB7Y+He4Go289WAdOk1m8R56yYi6Em48oQDCzBN/tsi86PSTXBDZefnexe1 cRtki8+TtxTiOcQxXfwRdIbnZDnj8wRc3gEVrIlM8nipE5gnCQvqda9jNZuH6TDu3+zO QiXWF45RfCy6pdHE7geD7219GulMzvokAOmnQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:references; b=iYn7Moibt80Vya+E5yYAYJdFVfN8l8CTVRsOeF1bdLR09OPPeYsFBxthtSNz8L/a3+ hUD8vw8CqSPwdXZj12hJ6LY2Qc0wpGY7OheHyKaU1CkbXDrVQWOAk+ECI4AggAsGdZvR Qp8OTCvqECazPhbZIlin+X10BsTUR08fTvpys= Received: by 10.142.156.2 with SMTP id d2mr2020728wfe.271.1213557144387; Sun, 15 Jun 2008 12:12:24 -0700 (PDT) Received: by 10.142.230.16 with HTTP; Sun, 15 Jun 2008 12:12:24 -0700 (PDT) Message-ID: Date: Sun, 15 Jun 2008 12:12:24 -0700 To: "Stanislav Malyshev" Cc: "Marcus Boerger" , "Felipe Pena" , internals@lists.php.net In-Reply-To: <483929DC.2060606@zend.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_15895_23300630.1213557144350" References: <46ccd1ab0804170742g142ed562t4f03339da549a820@mail.gmail.com> <48077BD2.2000107@zend.com> <48078168.1070801@zend.com> <496536410.20080525103752@marcus-boerger.de> <483929DC.2060606@zend.com> Subject: Re: [PHP-DEV] [RFC] Strict type hints (parameter and return value) From: chrisstocktonaz@gmail.com ("Chris Stockton") ------=_Part_15895_23300630.1213557144350 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Hello, On Sun, May 25, 2008 at 1:57 AM, Stanislav Malyshev wrote: > I see absolutely no use in "strict" mode. Moreover, I consider it harmful > as it teaches people not to use dynamic nature of PHP but instead pepper > their code with unnecessary checks and irrelevant errors. As I said, I see > no difference that could matter to PHP programmer between '1' and 1, and I > don't see why we should encourage making this difference. > I know there could be very special cases when it could matter, but > importance and frequency of such cases do not warrant, in my opinion, their > support by the syntax and the standard library of the language Maybe we should stop using the 1 and '1' argument, yes, they can be juggled to the same thing and I as well as others do see your point man. But try to remember, 1 !== '1' and PHP is not an end all language, often we have to communicate to strictly type systems, we need to be positive of what we send. I.E. XMLRPC Client sends string instead of integer to some merchant API changing the meaning of the request or voiding the transaction. PHP Made a design decision long ago to allow developers to have script types, by this decision with OOP5 and such strict type parameters would be made feature complete and be a additional feature for people to use who want to use it. IMO -Chris ------=_Part_15895_23300630.1213557144350--