Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110030 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 18105 invoked from network); 6 May 2020 09:16:05 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 6 May 2020 09:16:05 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 2F20C1804B4 for ; Wed, 6 May 2020 00:51:11 -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=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_NONE 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-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48]) (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, 6 May 2020 00:51:10 -0700 (PDT) Received: by mail-wm1-f48.google.com with SMTP id v4so4265802wme.1 for ; Wed, 06 May 2020 00:51:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=beberlei-de.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=pBOMwZWvk+jPgauX+wjsimzZvoeltH6p+Tln9h/Z1v4=; b=0QpvJUkXweWlm5+TGL2AGJ+hCUdoDG+q+EmHEs11uC0wRi1ovSRvUNdRp8ubIkfJ83 rq92jv3mA3Av7nP5bJBRVm1fqHeeFGR2ogoxCMOFEASvENC78dPZXxGSOHV4RoHCt2BK 25xGSpsDYajb1jPq9vZOgXr1O1Pzd4dgEN/lomVIbFST1xbvb5YawenCpjrToszY2a1T IDXgJ9tJs0man6WUxntFd5sEfiDJDzBfZ34LMoLIt+JW0kHq7zQD6EUddYvq85bKESUO Bcn4AhOIe4/YBn0UeRYeyL1uAwQ4q1MGeDHtETskIbJGuTUrlXzXdAt0rRuPbqisVAQh 2rvA== 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=pBOMwZWvk+jPgauX+wjsimzZvoeltH6p+Tln9h/Z1v4=; b=tSKKHgODjP9DuE8SBJGMGQ/eBum+IxOGMhe1IcR9yOKA/lFdpgW3OG5vze+8nFxDSw jeXqOIKGdyTHT+/owVX0Uz3xLwc2UXdAPDvHdbB0xY6pNW6Qn7cYDh0GIUjPlnr2PPgd B6h7r3nEWLx5B0DhCT0lCZ4UaNac0SZG3gK0I+QCCLi4dkjzlQ8Vbe+Ne5XukOjm1j7Q YNSn1nZju68g92dOyK1hhY1tNnZkA5MncXyFtrlmEDgZWrsGWWU5x1uP4ZwPQKQItLPx RQ5BkLBaQ/KzeuaY9unHxHtDe3NokQHNL/UvE8ZCikLmL5IDSy2MEs+VR+vEEsJGM6yp FPDw== X-Gm-Message-State: AGi0Pub/I+5xhbe0QJo/pDwoSWxelHp5V3tgAVEhIlrehQWE4DpCQFjR u9lBGutYzblb3hJzOzhWQG1WsUOwrojqLhD39bXM+w== X-Google-Smtp-Source: APiQypJHmzNz4OQoCyIqC3l0xOIMCDhOr0x5G1GR2B4klGouESK240J3/i3LFl5TBHSIupo8Em3GtZHrjC1xI7eD7Bw= X-Received: by 2002:a7b:cb86:: with SMTP id m6mr2822460wmi.64.1588751468780; Wed, 06 May 2020 00:51:08 -0700 (PDT) MIME-Version: 1.0 References: <65803616-5117-e9f2-ba31-f2f8c323dfe9@php.net> In-Reply-To: <65803616-5117-e9f2-ba31-f2f8c323dfe9@php.net> Date: Wed, 6 May 2020 09:50:57 +0200 Message-ID: To: Maciej Sobaczewski Cc: PHP Internals , Nikita Popov Content-Type: multipart/alternative; boundary="000000000000ef07a305a4f60626" Subject: Re: [PHP-DEV] Re: [RFC] Named arguments From: kontakt@beberlei.de (Benjamin Eberlei) --000000000000ef07a305a4f60626 Content-Type: text/plain; charset="UTF-8" On Wed, May 6, 2020 at 8:25 AM Maciej Sobaczewski wrote: > Hi Nikita! > > W dniu 05.05.2020 o 15:51, Nikita Popov pisze: > > Hi internals, > > > > I've recently started a thread on resurrecting the named arguments > proposal > > (https://externals.io/message/109549), as this has come up tangentially > in > > some recent discussions around attributes and around object ergonomics. > > > > I've now updated the old proposal on this topic, and moved it back under > > discussion: https://wiki.php.net/rfc/named_params > > > > Relative to the last time I've proposed this around PHP 5.6 times, I > think > > we're technically in a much better spot now when it comes to the support > > for internal functions, thanks to the stubs work. > > > > I think the recent acceptance of the attributes proposal also makes this > a > > good time to bring it up again, as phpdoc annotations have historically > had > > support for named arguments, and this will make migration to the > > language-provided attributes smoother. > > > > Regards, > > Nikita > > > > > I'm on the fence when it comes to the feature itself so I will skip that > part entirerly but I'd like to draw attention to one more problem. Many > PHP Manual translations translate the parameter names, too - both in > text, as well as in the function/method signatures themselves. > Can you give some examples? I checked a bunch of common functions in ext/standard, DateTime and PDO and all languages except Turkish seem to use exactly the same argument names as the english manual. Maybe there are individual runaways? In any case, the Turkish manual would have to change. It is misleading anyways, because for each of these ReflectionParameter::getName() would return the actual parameter name at runtime. > > We would need to fix every such occurence for every language (at least > active ones but there are still couple of them). Otherwise documentation > will become highly misleading. > > Most people probably use IDEs of course but it still doesn't change the > fact that the manual cannot be totally out of sync with what could > become the language syntax. > > Cheers, > Maciej. > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --000000000000ef07a305a4f60626--