Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:70938 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 66523 invoked from network); 30 Dec 2013 22:20:27 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 30 Dec 2013 22:20:27 -0000 Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 108.166.43.123 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 108.166.43.123 smtp123.ord1c.emailsrvr.com Linux 2.6 Received: from [108.166.43.123] ([108.166.43.123:59469] helo=smtp123.ord1c.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DB/96-33070-AA1F1C25 for ; Mon, 30 Dec 2013 17:20:27 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp8.relay.ord1c.emailsrvr.com (SMTP Server) with ESMTP id 611FA1A1621; Mon, 30 Dec 2013 17:20:24 -0500 (EST) X-Virus-Scanned: OK Received: by smtp8.relay.ord1c.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id EABA81A161F; Mon, 30 Dec 2013 17:20:23 -0500 (EST) Message-ID: <52C1F1A7.2000509@sugarcrm.com> Date: Mon, 30 Dec 2013 14:20:23 -0800 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Yasuo Ohgaki CC: Nikita Popov , "internals@lists.php.net" References: <52C1DB86.1030909@sugarcrm.com> <52C1E61B.8050404@sugarcrm.com> <004501cf05a9$e980fbb0$bc82f310$@tutteli.ch> <52C1EDC7.5060807@sugarcrm.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] GMP object and is_scalar() From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > Should it? PHP is weakly typed language. That doesn't mean types do not exist. That means values can be converted from type to type, but there's no type "scalar" - it is just a group name of a set of types. > One thing clear to me is users expects GMP numbers behave like > scalar numbers most likely. I don't think users expect anything like that, I don't see legitimate use case why users would expect is_scalar return true on GMP object. If the user is advanced enough to use is_scalar he should understand what that function does. Or user some other function that is more fit for their goals. > Yet another option for PHP 5.6 is to note GMP numbers as > EXPERIMENTAL. GMP is in PHP for a long time, why would it suddenly become experimental? -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227