Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:93766 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 69586 invoked from network); 4 Jun 2016 14:34:35 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Jun 2016 14:34:35 -0000 Authentication-Results: pb1.pair.com smtp.mail=danack@basereality.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=danack@basereality.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain basereality.com from 209.85.213.42 cause and error) X-PHP-List-Original-Sender: danack@basereality.com X-Host-Fingerprint: 209.85.213.42 mail-vk0-f42.google.com Received: from [209.85.213.42] ([209.85.213.42:35321] helo=mail-vk0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id FB/05-25194-9F6E2575 for ; Sat, 04 Jun 2016 10:34:34 -0400 Received: by mail-vk0-f42.google.com with SMTP id d127so149775405vkh.2 for ; Sat, 04 Jun 2016 07:34:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=basereality-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=2gfb3nbXUNbuLPjbdEGbYtsElfR67XeXy6w2XKZGMtA=; b=M1wdSgXUFxeK5+VzBWA6DT87bn4VWjWm4Sei6bRTDlxAv2g0witNBeoBUJFyY6Pcne wt+Jy4u3/Con3JSt6nQLY5e4FCObzfDY/dCKKxRgvz9zlf3HHwSarNcWMoJ8A9EptRp6 vwwzL0d2WbvXZeffsGRoJoPnEPWSvkYJ17HN22vZXVmlSQvUZ2Su5qWq22laTLVlpP1K Lf/HvBw06cavJdUMHilt+D95Ee5fRgS2vbBrCn1yfuFIY/h85UVTRO1JJz5C+pABgMGW eULygX4+NXuWsO/bihqwjyG/uFb0tmqu+r0TNJYNtq3nUOzdHIUxoB3HLSL1L+3CX/nZ akZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=2gfb3nbXUNbuLPjbdEGbYtsElfR67XeXy6w2XKZGMtA=; b=BN6jaBVQ/nrpgmb3jkDMQv46OBy0jAD2ywTP8Sl3Sj+GfgY3O39ksteiic/6sOkcAK QCBiA/yjFIMIYhgoH+bTTrg7KDGGboCeIUbO9tMqSux8/P1JsEuLx1iPn3c23N9kSC1t H48ISwPa+sKF2HjCe+bfK9oDxxUiDDGgzSwB5Gf8pvGVpRZGxxJC4Ex5ITaHw5hgXvEC AS93M7Dz+p5Fyd0ytoP/2UaRYfbI07N6YP8K//kXYyKfBn0CVudGZxYwbxkV9tn2t5WJ DUgK3pfB+NsAABtV3iNvnl6B2YPYVT+9kNQ4sYI7ySF8Y4iOI3Gs2mi9GQCXDyYDtQ/l hIEg== X-Gm-Message-State: ALyK8tL0aJOnZyGXO72c5Kv+miC8p3R/21snGOwECerrx/wlkgOby8+uY6aJrnfyhjtGd16RjmN/o9kVtlzgsg== X-Received: by 10.31.167.10 with SMTP id q10mr3470115vke.44.1465050871188; Sat, 04 Jun 2016 07:34:31 -0700 (PDT) MIME-Version: 1.0 Received: by 10.176.0.174 with HTTP; Sat, 4 Jun 2016 07:34:30 -0700 (PDT) X-Originating-IP: [78.147.11.74] In-Reply-To: References: Date: Sat, 4 Jun 2016 15:34:30 +0100 Message-ID: To: "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] [RFC DISCUSSION] typeof From: danack@basereality.com (Dan Ackroyd) On 4 June 2016 at 13:12, Fleshgrinder wrote: > Hi all! > > I prepared my first contribution to internals: > > https://github.com/php/php-src/pull/1932 > Hello FG, Having a standard way to get the type of a variable, that matches the name of how it appears in PHP is a good idea. The 'extended' parameter is not such a good idea, for various reasons but mainly because it's simpler for people to call is_callable() as well as typeof, rather than having to interpret the extended string to tell if a string represents a callable. The same is true for floats; it is easier for people to call is_infinite or is_nan rather than searching inside a string for 'infinite' or 'invalid'. cheers Dan