Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:109198 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 56797 invoked from network); 22 Mar 2020 03:24:36 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 22 Mar 2020 03:24:36 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 8FDD91804F3 for ; Sat, 21 Mar 2020 18:48:23 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,HTML_MESSAGE,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sat, 21 Mar 2020 18:48:22 -0700 (PDT) Received: by mail-wm1-f47.google.com with SMTP id d1so10542181wmb.2 for ; Sat, 21 Mar 2020 18:48:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=craigfrancis.co.uk; s=default; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=8+8wC6PqzL81JEX9Ei1hN/tAd8X2MAHGdy8ZNJuvzK0=; b=Q7VE5FbBxs+U6A/GOBnk2q6lcmuykMAZOKLbSoLZmrwijSNeFx1m72spY/sZ38bSiq yVpdAki+4yxsoX2KTCkPMC58S5ZuojkMk2Xvq8WNHlihupb2dagIW3GPnTWdd36l0cER TRPbozaMV/5OjBreE/NV/sMxXgQ87MfRpOxuw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=8+8wC6PqzL81JEX9Ei1hN/tAd8X2MAHGdy8ZNJuvzK0=; b=s5UMm8XPBgiXJ4oqKbaAV7hPggmVret3nVRmJ0G4/WnbtAE4PER5/mF7KV9RB77SCO pqB8YcJOv1irXuOLABF8Nwyb1iousWiPponRrOhDCS0WHsZhSa3WRJrngACeQ97BYgp0 dPJVesKI9zpo5bHO55Uwx+fyFxjpdS5thdtFp900rh4ZBWf1e5f1vlBBlhT5lwCGzlYK kcCD1IbsHwb8avJ+yt/zPi7Bgf5TCw3auklGzkmng8qVZ2C/doUe2VpuLv0dy6JVBDv/ /4u0hnHKNgp372kwIVvw3QWFklcBhG9hw3v+iIVWgPWq9v3gxz1oBUSxdH/TMCfFiKKB zohg== X-Gm-Message-State: ANhLgQ2zOa93BrAykFRBkg5bmi7EDxTY/jo62tz0y8xf4jjkzBS+OUK9 P+Who/8GrDLwjYkGVM0vH+/h5uIHW8m8SFXxIQics+XrtYBGIAHB X-Google-Smtp-Source: ADFU+vs7bHIUEVS72SJ+ZJoIGevJL8Gkdi/2VwoOGEMWXvng0I4ia5YMTdhXNWrsBf5q7uVv8YhtfASZbTixZ9k4THs= X-Received: by 2002:a7b:c185:: with SMTP id y5mr18813508wmi.179.1584841699352; Sat, 21 Mar 2020 18:48:19 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Sun, 22 Mar 2020 01:48:08 +0000 Message-ID: To: Jakob Givoni Cc: Ben Ramsey , PHP internals Content-Type: multipart/alternative; boundary="00000000000083fd9d05a167b647" Subject: Re: [PHP-DEV] [RFC] is_literal() From: craig@craigfrancis.co.uk (Craig Francis) --00000000000083fd9d05a167b647 Content-Type: text/plain; charset="UTF-8" On Sat, 21 Mar 2020 at 23:22, Jakob Givoni wrote: > I'll suggest is_from_literal() as a more precise formulation. Good suggestion, I've added it to the list of Open Issues (if we can determine the different ways this can be achieved, without affecting performance, then we can see what people prefer for the name). Sounds like you were having fun though :-) I was; although I must confess, I didn't recognise Derick until the talk began (then, suddenly, the voice from the PHP Internals podcast). On Sat, 21 Mar 2020 at 23:22, Jakob Givoni wrote: > On Sat, Mar 21, 2020 at 4:58 PM Craig Francis > wrote: > > > I'm happy to use a different name; but I should add that is_numeric() > isn't really a type, there are other functions such as is_writable(), and > the taint extension uses is_tainted(). > > Right, good points. However, to my logic, whether or not the value was > created from a literal is not something you can infer from the value > itself, it needs an accompanying flag or something. > > I'll suggest is_from_literal() as a more precise formulation. > > > I've talked to Paul Dragoonis and Derick Rethans recently (they both > kindly did talks at PHP-SW); when I mentioned it to Paul, I was told that's > where I should start looking, and that was the correct terminology; and > Derick helped confirm some of these ideas (but we were walking to the pub > at the time). > > Sounds like you were having fun though :-) > > > And while I keep trying, I don't know enough about C, or the internals > of PHP. > > Appreciate the effort. > --00000000000083fd9d05a167b647--