Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:106320 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 8059 invoked from network); 29 Jul 2019 13:44:33 -0000 Received: from unknown (HELO mail-io1-f54.google.com) (209.85.166.54) by pb1.pair.com with SMTP; 29 Jul 2019 13:44:33 -0000 Received: by mail-io1-f54.google.com with SMTP id e20so88590588iob.9 for ; Mon, 29 Jul 2019 04:09:11 -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 :cc; bh=++8TgTsgGmFUPInqchBbi73MC6JwQzsr7bT8NgAvTYw=; b=XzOfZINrCWXVemM0Sqfpc5tGWzLwbYrrtgaQO/toLc9zuiBqYkfGRx6YgiBMo+F/K2 vYeyPnkV9UTuUW52FvQQsYHHpMYm5GN7kbp+UA5H8eRQxhp8I1Ej13tkQ5ASPVjZ7C/x H6hRemdhRoXq7y+aZVI12FQGZ5/j4RS3PQ9sqVkzj/v69yDBTaQ3lXb6BiwdOKkjQp7B b6gIhh6dRxVXX7+bTaR83yBD5rk7Ygh+LkvWtQoDd5djQOYzygnkUCSTk6Fa58NkC9u3 +hI0mfXkfbZW0fOWgtDKPwOtjQR8t5FvO7FMe021JD3I70K2Wob/xEgttAIEPbnfJ1Ot ahtQ== 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=++8TgTsgGmFUPInqchBbi73MC6JwQzsr7bT8NgAvTYw=; b=gaOUUY6QsEqYdyANSgZzMdkjBcO60gnuXut6wHPrTDua2Bf2eByMclXmyd8MXNWI3l 9oMk0HnmFpTdDGZ98mTLjTb/u6koemMX7Du/3vau75tCHwZ1g+F5LMG3OXkUq7b1SVRy 0odWk3DKyQmMhADguUWFSd0ymue0kbLWuZeYoEjvl/QFW56NCk2iYUpILdDb02SzOIGU HNtudFPjYfH6utN0OxLQW1IbGX1xMouvDgEP2QDPpqasJj018cWitQcr5hRc1rfQULf1 uIesypFKKB2Ijpv2EVEVorhiSczudWHTBWOvJ9D7ztcz3T/TwVCyc2PSMRasxm7lVrII jk+Q== X-Gm-Message-State: APjAAAVU8ItEAOQG5ylABn3WDRZSEMkn90eHcUwhHUy/jnD5N74wA+uG hQDqliiVriImczZYvE8ZcZQsKYl2c3xPmJjF1vo= X-Google-Smtp-Source: APXvYqzCDcuj6qVDN2wC4Z6J5wFUiDud7OJaFCOQekqj2j+LzxBDI+HTbyq1pA3GXwTvOxMIYLI2LKXyMW7FRjZb2os= X-Received: by 2002:a5e:8f42:: with SMTP id x2mr14453101iop.35.1564398550959; Mon, 29 Jul 2019 04:09:10 -0700 (PDT) MIME-Version: 1.0 References: <9aba78c9-f04d-45b8-6c34-ad1c2472ef76@gmail.com> <75d04139-b944-f204-f988-959fa6f3e305@gmail.com> <8CD3B476-ABF9-4DB7-96D3-217064023854@gmail.com> In-Reply-To: <8CD3B476-ABF9-4DB7-96D3-217064023854@gmail.com> Date: Mon, 29 Jul 2019 13:08:57 +0200 Message-ID: To: Claude Pache Cc: Stanislav Malyshev , PHP Internals List Content-Type: multipart/alternative; boundary="000000000000eacb28058ecfebed" Subject: Re: [PHP-DEV] [RFC] Explicit call-site send-by-ref syntax From: ocramius@gmail.com (Marco Pivetta) --000000000000eacb28058ecfebed Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Jul 29, 2019, 10:40 Claude Pache wrote: > > > > Le 28 juil. 2019 =C3=A0 21:12, Marco Pivetta a =C3= =A9crit : > > > > On Sun, Jul 28, 2019 at 9:06 PM Stanislav Malyshev > > wrote: > > > >> Hi! > >> > >>> Nah, by-ref is pretty much avoided in OSS packages, but we can surely > >>> survey the ecosystem to verify this. > >> > >> I literally work with code that uses references every day. So may be y= ou > >> haven't encountered it but the attitude of "nah, never happens" I thin= k > >> is a bit misplaced. > >> Also please remember not all PHP code is latest composer packages. In > >> fact, most of it isn't. > >> > > > > I do work with code like that: the teams maintaining these codebases ar= e > > actively removing by-ref calls when they encounter them. > > > > Marco Pivetta > > Do your teams actively remove direct calls to array_push() and > array_multisort()? In any case, I=E2=80=99m sure that most PHP developers= don=E2=80=99t. > Yes: usually replaced by `[]` or wrappers of those functions that de-reference the variables, so that no references are used. > --000000000000eacb28058ecfebed--