Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:101633 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 37101 invoked from network); 20 Jan 2018 01:25:32 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 20 Jan 2018 01:25:32 -0000 Authentication-Results: pb1.pair.com header.from=andreas@dqxtech.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=andreas@dqxtech.net; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain dqxtech.net from 209.85.215.53 cause and error) X-PHP-List-Original-Sender: andreas@dqxtech.net X-Host-Fingerprint: 209.85.215.53 mail-lf0-f53.google.com Received: from [209.85.215.53] ([209.85.215.53:40126] helo=mail-lf0-f53.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 01/80-12394-B8A926A5 for ; Fri, 19 Jan 2018 20:25:31 -0500 Received: by mail-lf0-f53.google.com with SMTP id h92so4152282lfi.7 for ; Fri, 19 Jan 2018 17:25:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dqxtech-net.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=8TsxkLaAyX9TXYyOGDJI8oYSghq6hW9hyZEKASQfBMU=; b=Lh1em82w6ffM/ee3kMJTXpJRC5etUzIgtFXe+tXPh+EKYhyIcoGDmB+863WsyvLrx3 X5zXdczMyx2bOVvWukoAQjcxEuQF/pjqPOVUYvmraToZhG/trVrh5LKQ2OjtiA+oeYcP WtN46IXldq+m6GKnYDYhUSfbip/ncDZ2jAvI0XrSWwlVDtmcORlcMvso/qfee38plhDL OovyXkNUCTJCEw5YKseL/gPH+rs3xYrOoQLmusuy4A5J/0pg9LLrLo4bJrIzrwV2mYCR pQLAabax8rG8kA90QBWIAcx+AdUogg+DB+j35GvEmy1hX2lOm3dYrzNA58R8T1RjFNsr Rj+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=8TsxkLaAyX9TXYyOGDJI8oYSghq6hW9hyZEKASQfBMU=; b=B24PO82Ox71ejNzi2yE7fxRAOEyrEY7IDLcG/d/3Xl7YHeT+68NI8+Mg8ueJfAv4Pw kesx3GrJKSsWVIimobdgm1yaxPN1jjORuh72geAULDrLXAt8BLvw3x16kmsouitZu5Bu QF00L/iH433kIjEpkUfmC2euS/uZPgiHW4nkcU/Jhk51dh5SbapWlprLOEg/2oDF0Ef3 /8xowoyyGYEcEsTzShvWPtBukGpoV4QXpFG/LGkIhwiuQPCNI8lU/GfvmKM7kiMCMQEy 9g8AyVrQFHdinROrSeJi7Lv3J5fl7ARr4kFFlrWEP7vIFlCfa0mTrrWHmoX6Jsu8f1jO pV0g== X-Gm-Message-State: AKwxyteksD4zVGFz055Pdt3Vsjcvj9Jel2ZNhwaiIRUQAiXhnO9acpiN VGBq3IybFAd05B6Pb0UamW9KAYAs X-Google-Smtp-Source: AH8x2268tKz2rTUY9fjNGwTxpCK7qrVM70VLT5CZljj1KiCqTzS2R9c0U29B0LLwtK+sDfG7E2Srjw== X-Received: by 10.25.170.208 with SMTP id t199mr146707lfe.53.1516411527676; Fri, 19 Jan 2018 17:25:27 -0800 (PST) Received: from mail-lf0-f46.google.com (mail-lf0-f46.google.com. [209.85.215.46]) by smtp.googlemail.com with ESMTPSA id l66sm1861822lfe.15.2018.01.19.17.25.25 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 19 Jan 2018 17:25:26 -0800 (PST) Received: by mail-lf0-f46.google.com with SMTP id q17so4152189lfa.9 for ; Fri, 19 Jan 2018 17:25:25 -0800 (PST) X-Received: by 10.46.77.72 with SMTP id a69mr169304ljb.65.1516411525254; Fri, 19 Jan 2018 17:25:25 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.163.71 with HTTP; Fri, 19 Jan 2018 17:25:04 -0800 (PST) In-Reply-To: References: <9a4e54d1-10d8-889e-e705-fe473e2e3713@gmail.com> <3aa2372c-c31a-d41a-f455-35ce400b382b@gmx.de> Date: Sat, 20 Jan 2018 02:25:04 +0100 X-Gmail-Original-Message-ID: Message-ID: To: Sara Golemon Cc: "Christoph M. Becker" , Stanislav Malyshev , PHP internals Content-Type: text/plain; charset="UTF-8" Subject: Re: [PHP-DEV] null coalesce addition assignment operator ??+= From: andreas@dqxtech.net (Andreas Hennings) On 19 January 2018 at 16:12, Sara Golemon wrote: > On Thu, Jan 18, 2018 at 7:13 PM, Christoph M. Becker wrote: >> On 18.01.2018 at 23:58, Stanislav Malyshev wrote: >> >>>> I propose even more such operators: >>>> null coalesce addition assignment ??+= (for strings and numbers) >>>> null coalesce subtraction assignment ??-= >>>> null coalesce increment ??++ >>>> null coalesce decrement ??-- >>>> null coalesce multiplication assingment ??*= >>> >>> I think this is taking it too far. If you want language like that, you >>> always have APL :) >> >> Why do we discuss extensions to an operator which has still (after >> nearly two years) not be implemented due to implementation difficulties? >> > Am I the only one who looked at the original post and assumed he was > taking the piss? > Similar to the jokes about spaceship assignment <=>= and > equality/identicality assignment === (not to be confused with > identical non-assign, which is ===) and ====. I can definitely say it was not a joke. I can see myself and others use the ??+= and also ??++, and would have used them in the past, if they had been available. The others, I don't care as much. For me, a good enough conclusion of this conversation would be one of: A: Yeah seems useful, but let's wait (or work) until ??= is implemented and released, and observe how it is being used. B: No one will ever use it, and it would hurt the language.