Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:109660 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 23298 invoked from network); 15 Apr 2020 18:20:00 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 15 Apr 2020 18:20:00 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id F379F1804CC for ; Wed, 15 Apr 2020 09:49:57 -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-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-oi1-f175.google.com (mail-oi1-f175.google.com [209.85.167.175]) (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 ; Wed, 15 Apr 2020 09:49:57 -0700 (PDT) Received: by mail-oi1-f175.google.com with SMTP id k9so14028319oia.8 for ; Wed, 15 Apr 2020 09:49:57 -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=eE/FIZxw2XEi3kZj0lSE5g0MzzDx9ofeHJ4Wk2ysFz4=; b=jIH84fYEmS1XRle5906ac3VhzUzDV1/mV/3gdyspP7sih0RxUTK01flOpaFY9SvY+S Fe1KaDMUA3rRFxXVq5ReC5FaVGhC80B/xVMvD8kMnCVkGZhGImyqeey98XaEXcIS79lT kh2Zm5i3mxYOm2PtXcv60z7ZrMurnD2eL51Iu5hP47jezpMavuIkYwtHm42p5C6KKzal bXEcbx6I1UjxU+1mKNWJy2kunoBxhQZczUiEk4/VSvAGSr1GmKPry5waQ6wWRRswoawd joy/yi/w4uHsBp34GkvOk7UkQl5q9iiFn9+3BrPe+MM1uC+dfwPxlm8uDRduPtJyMrYW J5ww== 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=eE/FIZxw2XEi3kZj0lSE5g0MzzDx9ofeHJ4Wk2ysFz4=; b=PZTZZA1snJscBRVlSUaNrsZuhC97DYMGrWXIW7f3j5VKpyy7zJTz+GfI+vGl0lal/Q g91ODUh9AK3dpkckSDKlCuxPkRuJdlh8LGNmcn9iB1+xP1rq8vlYDPaNTFv121z1VMS1 TaN5iE7G3x3YOFDuy+Z3+1Q0S9QSsecuQkneMEX08nzRwyfkkZ/Wvv45PFCddSMGNEGr OIwoKOwxh1nzPxg4LxBBlWykrBJNZ4xDQzZE2mtzqEn65HXQT8YlqUoV5qw2kBQoaGEc riWGLJWx/w8sUFJWimyyIUNPPil9/rPgZAvdpQGWBeTRnd9ivbMH/z0PrQKWe4oiISMC 6zww== X-Gm-Message-State: AGi0Pub+F1lvwy7Ksh4CcuLP0E6IGUjBsZF5h1woCGYpH1GLotWpZiYI tDL2pGU5uc9dU/8xzlC+8CKUd14mumkeVfyqClglF6/w X-Google-Smtp-Source: APiQypL/Bf1o1fGhN0l9KB4SsC3b6uhP81QzMncHZK4nmlMYS8H1DyWwm7KhlaNgG3zT0+XN9R/jP6lT0so3JVvyMZI= X-Received: by 2002:a05:6808:485:: with SMTP id z5mr112130oid.78.1586969396848; Wed, 15 Apr 2020 09:49:56 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Wed, 15 Apr 2020 18:49:44 +0200 Message-ID: To: Marcio Almada Cc: PHP Internals List Content-Type: multipart/alternative; boundary="0000000000002b2faf05a3571bc9" Subject: Re: [PHP-DEV] [RFC][DISCUSSION] PHP Namespace in core From: michal.brzuchalski@gmail.com (=?UTF-8?Q?Micha=C5=82_Brzuchalski?=) --0000000000002b2faf05a3571bc9 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Marcio, =C5=9Br., 15 kwi 2020 o 18:39 Marcio Almada napisa= =C5=82(a): > > > > Hi internals, > > > > I hope you're doing well. > > > > I'd like to announce the PHP Namespace in core RFC for discussion. > > The RFC is authored by me together with George Peter Banyard and it's > > purpose > > is nothing more like to allow the use of PHP Namespace in the core. > > > > The RFC is described at https://wiki.php.net/rfc/php-namespace-in-core > > > > Best Regards, > > Micha=C5=82 Brzuchalski > > Hello, > > Even though I'm fond to the idea of languages having the official > stdlib contained > into a single space, there seems to be no practicality on a \PHP namespac= e > usage > at this point IMMO. > > We would be in a situation where things are either mixed in and out > the new namespace > - Should I `use function PHP\{json_encode, json_decode}` or was it in > the root??? - or > everything that already exists must first receive an alias into this > new namespace, to allow > consistency... but then there would probably be no plans ever to > actually move existing stuff > into the new prefix in the future. > > You've misunderstood the idea. Standard library functions classes etc. are not language features. It's not a purpose of this RFC to move existing functions from the standard library but to allow core language features to use it. Described examples show benefit in use for symbols tightly coupled to features PHP as a language delivers. Most of the standard library function can be replaced by implementations in PHP or by wrapping around a C library. The features tightly coupled with the language is for eg. the Reflection mechanism, PhpToken class as described. Upcoming PhpAttributes for which proposal is a work in progress. Those all features will not likely be moved to PECL and this RFC proposal is to allow features like that to use PHP namespace. Cheers, Micha=C5=82 Brzuchalski --0000000000002b2faf05a3571bc9--