Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:106823 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 21629 invoked from network); 31 Aug 2019 04:20:09 -0000 Received: from unknown (HELO mail-qk1-f179.google.com) (209.85.222.179) by pb1.pair.com with SMTP; 31 Aug 2019 04:20:09 -0000 Received: by mail-qk1-f179.google.com with SMTP id d26so274027qkk.2 for ; Fri, 30 Aug 2019 18:52:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dqxtech-net.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Nz60noY7/vNjMSFXeBtgtEXmEZaMWOJSZOntFCLiUT4=; b=zVnvGvzs3OPEkUShzoGDGU8uhD/OnYtx0YoGAR/6KqmxteXikwchN3IULHP7xH1ONG eShk8sOSpd9Q7fSM3SN3GNlHdsFb4CYkf7fCe0t6GHT8qkyGwfhkRIiZ4O4b4oidZt+v 6xaLTG0VLFCnM54JsqqJzTv2bEEwJtpBs1TRypEtTwCXd+NAzryS7Jk+FlNE4AeZMWlw DmMVC4AK1X1FNSAELM10B8PklJlQYbALqV+geevDJYgcJESaepfSvFagNLM8Wt6o+CLn 6WKCP9atAg8bFkTz9x3ks2zyTvgrwL3IP5oZCxcmmyKUmGaKzVJFT+wu2e73Gjbu0OK1 0IoQ== 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=Nz60noY7/vNjMSFXeBtgtEXmEZaMWOJSZOntFCLiUT4=; b=ANw9YHLs9b5WcQEnbJ9Pg2D8RFkO0AIlH7wfnTLtT0VXv4kRNmXAK6BKHHhBeYtyG7 13UGfnItRHu2ETQT3ye7sn8KEkjlHDPfIhbPA5QgYXlFQhwnYIh99tduJPgKHvGWH6+H VEk8gFrg2KGoaO1pIW2sahu4R3SP/7QBZWhQIJb4Xl+UP93TMfpIbTI4h5vt6c0SRMO4 uaO/6MXXtJgHhJJiBrAwxi9zXSuLYQSOWI8jV0RqElyhU7AV2tmF17/zZD6SE4atEqUx jBhQ/NPpmvvmtgMOZo49Uy0MW70Po7i79MJl6dF1v7+MfqrI6zDFM0UX9CmbflUg9Kqr um6A== X-Gm-Message-State: APjAAAWAtzXlQ2Hj4gq5vwutNaMmv3Gw9UO0vL+gjtE4WNG8lCe/mR6g KUg1XE3ELfpOeMqi35+XDqhzP2WsnBY= X-Google-Smtp-Source: APXvYqy2y7VK0SHy9x0juhbGZvfljXgzR41R33nkjaTOvQ62804FYTzN9SnQvCo3w8jjCXMbQ+/kDQ== X-Received: by 2002:a05:620a:1241:: with SMTP id a1mr17473403qkl.136.1567216376145; Fri, 30 Aug 2019 18:52:56 -0700 (PDT) Received: from mail-qk1-f177.google.com (mail-qk1-f177.google.com. [209.85.222.177]) by smtp.googlemail.com with ESMTPSA id c23sm959619qtn.85.2019.08.30.18.52.54 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 30 Aug 2019 18:52:55 -0700 (PDT) Received: by mail-qk1-f177.google.com with SMTP id m10so7903769qkk.1 for ; Fri, 30 Aug 2019 18:52:54 -0700 (PDT) X-Received: by 2002:ae9:e007:: with SMTP id m7mr18325806qkk.87.1567216374614; Fri, 30 Aug 2019 18:52:54 -0700 (PDT) MIME-Version: 1.0 References: <595cafef-4c5d-d991-605d-d55bded017b4@thelounge.net> In-Reply-To: <595cafef-4c5d-d991-605d-d55bded017b4@thelounge.net> Date: Sat, 31 Aug 2019 03:52:43 +0200 X-Gmail-Original-Message-ID: Message-ID: To: Reindl Harald Cc: Chase Peeler , PHP internals Content-Type: text/plain; charset="UTF-8" Subject: Re: [PHP-DEV] Bringing Peace to the Galaxy From: andreas@dqxtech.net (Andreas Hennings) On Sat, 31 Aug 2019 at 03:40, Reindl Harald wrote: > > > > Am 30.08.19 um 20:56 schrieb Andreas Hennings: > > In one of -these modules I initially used the ?? null coalesce operator. > > Then I had to replace all of the instances of ?? with the more verbose > > old-school code, to make it compatible with older PHP, because there > > are still enough Drupal 7 installations out there which have not > > upgraded to PHP 7 yet. > > I also had issues with old 3rd party libraries, which stood in the way > > of PHP version upgrade. > > > > In a world with "editions" per file or per package, such projects > > could more easily use the newest PHP version, while the old libraries > > would continue working. > > no, it could not, when these days installations aren't running PHP7 at > all you won#t have support for new features If "editions" (the way I imagine) had been introduced prior to PHP 7, we might now have a PHP 7 engine that would still support code written for PHP 5.x. There is a limit in how far this makes sense. In a lot of cases, what "breaks" in PHP7 was already broken to begin with. So in a way the BC breaks can be a good thing, they force people to fix the mistakes from the past. > > you can declare what you want on top of the file - when the server is > sloppy mainatined and running stone old software you simply can't use a > recent feature > > just stop supporting such unmaintained setups and they will disappear, > break them as hard as you can! > you need to distinguish two different things here: - server infrastructure / php version. - the actual PHP code in the project, which might be a collection of custom code and various 3rd party packages with different age. upgrading the server infrastructure and php version is easy, compared to upgrading or fixing the PHP code itself. The only reason why people might stick with an old infrastructure and php version is because the new version might break their legacy PHP code. As said earlier, I would claim that increased BC tolerance with opt-in strictness per file would make it more likely that people use the latest php version available.