From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-2.9 required=3.0 tests=AWL,BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_BL_SPAMCOP_NET,SPF_HELO_PASS, SPF_PASS,UNPARSEABLE_RELAY shortcircuit=no autolearn=no autolearn_force=no version=3.4.2 Received: from nue.mailmanlists.eu (nue.mailmanlists.eu [IPv6:2a01:4f8:1c0c:6b10::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 8B15E1F601 for ; Sun, 4 Dec 2022 22:48:36 +0000 (UTC) Authentication-Results: dcvr.yhbt.net; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.b="E0v6XQ4O"; dkim-atps=neutral Received: from nue.mailmanlists.eu (localhost [127.0.0.1]) by nue.mailmanlists.eu (Postfix) with ESMTP id 205527E7B3; Sun, 4 Dec 2022 22:48:24 +0000 (UTC) Authentication-Results: nue.mailmanlists.eu; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ruby-lang.org header.i=@ruby-lang.org header.a=rsa-sha256 header.s=s1 header.b=E0v6XQ4O; dkim-atps=neutral Received: from xtrwkhkc.outbound-mail.sendgrid.net (xtrwkhkc.outbound-mail.sendgrid.net [167.89.16.28]) by nue.mailmanlists.eu (Postfix) with ESMTPS id 066597E788 for ; Sun, 4 Dec 2022 22:48:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ruby-lang.org; h=from:references:subject:mime-version:content-type: content-transfer-encoding:list-id:to:cc:content-type:from:subject:to; s=s1; bh=CrEVrrSNrKJ/C7qTDN/+/DColT9oAq2j7DCQIqXXuwU=; b=E0v6XQ4OEigmMYVwge2rbHWJCucoilIyQs9xCF30ojOtDRcXzUBKCzenJDpFYq0GRl8Y 7lQyezqnlhL592Gm0WVLGPVRv9Hw5RYDiVrrWlqESJnArMYi6jiKGa3Bf4pTBXUNhSqYUQ tbNWRVd8n09xpO8bjFsb7lG44vpUOpLeE0pWmxDJXxZfrtSUUXuFd49Fr1zLtY53lQ0Q+w RRAxBOX3bCoUxOpq6pn93QrpeTOGQk+jJXJEsAVHtq5HQoziEjJ4/93yGdOwobxAFyRM3y wfyg5/T2VOaGXRYB14YjxrADcezNgjHtXWlAL6HA2WV8Hd3G7mmOtPbcvTZC8aOg== Received: by filterdrecv-557d69979-lz2nq with SMTP id filterdrecv-557d69979-lz2nq-1-638D23AE-9 2022-12-04 22:48:14.322494695 +0000 UTC m=+1467760.738216533 Received: from herokuapp.com (unknown) by geopod-ismtpd-5-2 (SG) with ESMTP id SB0bM6eAQEWzUIxYM6Y6Lw for ; Sun, 04 Dec 2022 22:48:14.210 +0000 (UTC) Date: Sun, 04 Dec 2022 22:48:14 +0000 (UTC) From: "shugo (Shugo Maeda)" Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Redmine-Project: ruby-master X-Redmine-Issue-Tracker: Feature X-Redmine-Issue-Id: 19134 X-Redmine-Issue-Author: shugo X-Redmine-Issue-Assignee: matz X-Redmine-Sender: shugo X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-Redmine-MailingListIntegration-Message-Ids: 87556 X-SG-EID: =?us-ascii?Q?o0C=2FsDUd4ZFGiDZCTbvVjqibxcpCfydz4lwnBQWyXZ+Plw=2FfhrG0CQPbrktOPX?= =?us-ascii?Q?NfKIrb7bilCwkXET66DNxoL2oPYiGT9L1Ety2g0?= =?us-ascii?Q?so44fQNHpeLptgLWvyLRJdr3A8HkaP7fc3zBXgT?= =?us-ascii?Q?TTMm84+dU=2F5PPSNjVIXIsRJjQfX8xD0hqFZEBNC?= =?us-ascii?Q?WCYnUX6QTudNNxRfxP0HA4oO17ufFDvLma4bAom?= =?us-ascii?Q?8A8Cs1ziZw2Z2ktW4fjZhN7Uo04QwL7NT0Xsc0q?= =?us-ascii?Q?F1miTeJYPe+71eQlrMs2w=3D=3D?= To: ruby-dev@ml.ruby-lang.org X-Entity-ID: b/2+PoftWZ6GuOu3b0IycA== Message-ID-Hash: WORCAGTE7DPZ4KK3S5LH7JML4SQ5ZEBQ X-Message-ID-Hash: WORCAGTE7DPZ4KK3S5LH7JML4SQ5ZEBQ X-MailFrom: bounces+313651-12dc-ruby-dev=ml.ruby-lang.org@em5188.ruby-lang.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.3 Precedence: list Reply-To: "Ruby developers (Japanese)" Subject: =?utf-8?q?=5Bruby-dev=3A52011=5D_?= [Ruby master Feature#19134] ** is not allowed in def foo(...) List-Id: "Ruby developers (Japanese)" Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Issue #19134 has been updated by shugo (Shugo Maeda). Eregon (Benoit Daloze) wrote in #note-5: > IMHO if `...` is used then `*`, `**` and `&` should all be forbidden (a SyntaxError at parse time). > Because that way is the best for optimizing delegation. > And also taking apart `*` and `**` is arguably not really delegation anymore. `&` is allowed in 3.1, so it's a breaking change to prohibit it. ---------------------------------------- Feature #19134: ** is not allowed in def foo(...) https://bugs.ruby-lang.org/issues/19134#change-100493 * Author: shugo (Shugo Maeda) * Status: Closed * Priority: Normal * Assignee: matz (Yukihiro Matsumoto) ---------------------------------------- `*` and `&` are allowed in the body of a method with `...` argument forwarding, but `**` is not allowed. ``` def foo(...) bar(*) # OK baz(&) # OK quux(**) # NG end ``` Is it intended behavior? It seems that parse.y has code like `#ifdef RUBY3_KEYWORDS`, and if RUBY3_KEYWORDS, `**` will also be supported. -- https://bugs.ruby-lang.org/