Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:70911 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 63736 invoked from network); 29 Dec 2013 22:13:07 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 29 Dec 2013 22:13:07 -0000 Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.217.177 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.217.177 mail-lb0-f177.google.com Received: from [209.85.217.177] ([209.85.217.177:50916] helo=mail-lb0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C7/50-62207-27E90C25 for ; Sun, 29 Dec 2013 17:13:07 -0500 Received: by mail-lb0-f177.google.com with SMTP id q8so5098934lbi.8 for ; Sun, 29 Dec 2013 14:13:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=vLcAMGpYtT0tcS3aHTAjTRzwjcAi0pP80Lt7yAeBSvw=; b=ErueovwZLXdsecPlCzQVHVvpOKxfw8pikcgBErAimFGybdIH9hPgihQfUQfCZ2UmTz TcH+a81YN1sTH4BA6iKUX8Tnq8phbnL3DJdWcEkMNzHFtJHZ92I4o949f9Lcf9hEPmGo xavs196IWI8zaH42tFcgNxIwh4WQP/WPatQWYI4+M93MpO4g+e6zXVdxB7MsUawM6B2q lMMk/ungYmC76pzBuX9Iqu0e8j/hCA2VV5LDMf1RrdoQjfQGhkNFzNkFbJR8ZB0K5AMD KClDi8wpTusRV94nqsWtf0iVUHpgcOBeJWKqC7KOxJCwGGxPzdzPmiERdiYEMr0OP/Fx bRNw== X-Received: by 10.112.159.69 with SMTP id xa5mr68672lbb.89.1388355182494; Sun, 29 Dec 2013 14:13:02 -0800 (PST) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.112.6.68 with HTTP; Sun, 29 Dec 2013 14:12:22 -0800 (PST) In-Reply-To: References: Date: Mon, 30 Dec 2013 07:12:22 +0900 X-Google-Sender-Auth: j0e1fEZaY8Cjke7sC0AdJjTkaCQ Message-ID: To: Nikita Popov Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=001a11c2ba7e798b0a04eeb3a107 Subject: Re: [PHP-DEV] GMP object and is_scalar() From: yohgaki@ohgaki.net (Yasuo Ohgaki) --001a11c2ba7e798b0a04eeb3a107 Content-Type: text/plain; charset=UTF-8 Hi Nikita, On Mon, Dec 30, 2013 at 2:54 AM, Nikita Popov wrote: > Sorry, I don't understand what you're saying. Why would is_scalar return > true for an **object**? Since GMP object works just like numbers, this could cause bug that users assume it is "number" or "scalar". Variables are promoted to GMP object when math operator is applied. (This is nice, IMO) GMP objects works like number mostly, this can be cause of bugs in user scripts. It would be more intuitive for users if GMP object is handled as "number" IMHO. Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --001a11c2ba7e798b0a04eeb3a107--