Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:111478 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 92876 invoked from network); 11 Aug 2020 17:37:27 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 11 Aug 2020 17:37:27 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 36CCE1804AA for ; Tue, 11 Aug 2020 09:36:55 -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,FREEMAIL_FROM,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-Virus: No X-Envelope-From: Received: from mail-il1-f169.google.com (mail-il1-f169.google.com [209.85.166.169]) (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 ; Tue, 11 Aug 2020 09:36:54 -0700 (PDT) Received: by mail-il1-f169.google.com with SMTP id k4so4637532ilr.12 for ; Tue, 11 Aug 2020 09:36:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=pfsCl95iWyUpBRORMKogmfvIQzW4PrqsqMNBuZwDX34=; b=rj5IC+ne22jQJtIB7vmcLBv4H4Xq9mK0e3hb3LZNpkjKSon//r12slul/baI1Uxabk nd36nFK7DdZh0d5BtLE24pqdvpCcerfrO3bm2ClQF0Dli5VFJECSf0+BDeFEsJDeaLXk NzVO2BixdyPTyppAWtWISWwrOzntduqbr0y/W555L4SruKuQr+JHHFHnDonBEJ8/1t4M gt3naKMGhldFsXA8uK1dIwAx35HrEuumDbzMFgVY55BumWH2MZb1ofI0EQwdbN4u2hgK aR7IOpTb65peLcSrIEiizYfGUra/V9MJeT7PdTDY3r9qyvIXzQIktxghOpxDTFr45c7C vuqQ== 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; bh=pfsCl95iWyUpBRORMKogmfvIQzW4PrqsqMNBuZwDX34=; b=a5npjNUxR9c0dABKw7iIKvmgKqkrgYOAoFu5baxo451Wq9doixMsercBkWY3umlcfD 0F+ax3XDQip2z0te/FvuyUg9pa4HNAkMaDQJfIEm1EPtLSIAw2zQ7jm5jA8XaT08z8TS GWuCmfbcqJFw4BFn0c8otk/xWRV095+pkzNGmsLm0eb/wmFSfYekDJEu3zZkDvIci27j MrBR/VsqGQnxzonvbPF82onQk6cMMKBwyN8WwcjL8IQmkH3abbTY1kDDZkob0xq3/P3Z Gj4C/i5n7siefelZhInQUU6lbIe0xV2+2NcNObjFV77G/dTMXHEsX/8w7FVo7fvgyfaz R3qA== X-Gm-Message-State: AOAM532DSvGdkZYXW7PfpwKxj+Dn0TgZn0uAWYA+OAZNmu0T8jNQsC22 80L1WPN9PyBk6uuQ4g17Key3fp6SUZNbb4xcMg4VHf1h X-Google-Smtp-Source: ABdhPJwddqjLgRZoQtHE19PYzQESKK0+yDTmoQeQ8mzQL/qJN3NIYtQN+RLEcPpzoBlHyMxtY24palImz2v/llwl5SY= X-Received: by 2002:a92:d306:: with SMTP id x6mr25020244ila.229.1597163811574; Tue, 11 Aug 2020 09:36:51 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Tue, 11 Aug 2020 17:36:39 +0100 Message-ID: To: PHP Developers Mailing List Content-Type: multipart/alternative; boundary="000000000000a317d805ac9cad77" Subject: Re: [PHP-DEV] [VOTE] Shorter Attribute Syntax Change From: rowan.collins@gmail.com (Rowan Tommins) --000000000000a317d805ac9cad77 Content-Type: text/plain; charset="UTF-8" On Tue, 11 Aug 2020 at 17:07, Theodore Brown wrote: > > I would suggest "Kinds of symbols used". > > @@ is easier since it only uses one kind of symbol, rather than > switching between two or three symbols which are often on different > sides of the keyboard. > Honestly, this feels about as objective as "number of pixels" - feel free to use it your own vote, but it doesn't feel headline-worthy. > > > fact that the @@ syntax makes attributes easier to grep for. > > This can be a simple Yes or No. With @@ or @: you can type those > symbols followed by the attribute name to grep for it. With the other > syntaxes and attribute grouping, if the name isn't unique it may be > difficult to search for since you can't rely on a unique leading symbol. > Surely *all* of the syntaxes will be easily greppable once adopted, because any instances that aren't attributes will have to be fixed (other than those in comments and strings, which can happen with any of them). Any of these will show up very little outside attributes once you've fixed parse errors: #[ @[ @: @@ "<<" is possibly an outlier here IF you use bit shifts a lot. To filter further, you can write a quick regex to match the attribute name; untested, but something like: /#\[[A-Za-z0-9\\]+[\(\]]/ /@\[[A-Za-z0-9\\]+[\(\]]/ /@:[A-Za-z0-9\\]+/ /@@[A-Za-z0-9\\]+/ /<<[A-Za-z0-9\\]+(>>|\()/ That last one has a small chance of matching something like "$foo = $bar<> has a small disadvantage here, but it's also been thoroughly rejected in a previous vote, and seems unlikely to suddenly make a comeback. Regards, -- Rowan Tommins [IMSoP] --000000000000a317d805ac9cad77--