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,RCVD_IN_DNSWL_HI, 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 98D9F1F61A for ; Wed, 14 Dec 2022 07:13:22 +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="okk0Aozu"; dkim-atps=neutral Received: from nue.mailmanlists.eu (localhost [127.0.0.1]) by nue.mailmanlists.eu (Postfix) with ESMTP id BCFE07E965; Wed, 14 Dec 2022 07:13:06 +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=okk0Aozu; dkim-atps=neutral Received: from o1678948x4.outbound-mail.sendgrid.net (o1678948x4.outbound-mail.sendgrid.net [167.89.48.4]) by nue.mailmanlists.eu (Postfix) with ESMTPS id 8E5257E962 for ; Wed, 14 Dec 2022 07:13:00 +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=95bxxkMLZHGd+Ry2rVwsDpcxHeZj/bcL/HHTfNSMUlk=; b=okk0AozuOPiy+41bHcmLDIZrPkXfm5FVrutwMVwBRvtNNPPwKuD/K7FF9ILzEL7ttKeE GqfD9F50EPuilxa8VnGtrIAzHI2RgAzm2vta59oXg1yc8O9mUMuyYr+av/F1vBLWLG/qav QHUusAVLTjA7vLQN0PSHJmeL5wZ4YKjaniUmun7ddduY0hDCerkuDA7iTzvECdxe2r2cxE kIJb9el5TnyntDDB7eG4037RQSANeqlvd4hpvBgjedHWoEiANxRf3F25HjVW20ugYxCjz6 QkrbbIsmzkxktCrYFt5xdu11UWfj8/Vp5KPFjPBfq8RwWqoWVzQqEtZwtQElE7QA== Received: by filterdrecv-557d69979-cx8s6 with SMTP id filterdrecv-557d69979-cx8s6-1-6399777A-C 2022-12-14 07:12:58.510199843 +0000 UTC m=+2275634.758447113 Received: from herokuapp.com (unknown) by geopod-ismtpd-5-1 (SG) with ESMTP id lPyEX3_QS9-b5plG0w6mIg for ; Wed, 14 Dec 2022 07:12:58.397 +0000 (UTC) Date: Wed, 14 Dec 2022 07:12:58 +0000 (UTC) From: "mame (Yusuke Endoh)" 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: mame 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: 87678 X-SG-EID: =?us-ascii?Q?YbSlef6ZOa=2FS=2FuqSxXRzl42MttQDxKOujGe43WuBjI7JKMg2OkmRsyzG5za6L9?= =?us-ascii?Q?e1flZkYZ9OViVy5Lc4acvpZpi1MBgPb6+=2FsnlVW?= =?us-ascii?Q?uK9IvJtFvoF61X0lN+1=2FoGsDnooyTaMlodVvi1s?= =?us-ascii?Q?2Ewfw8YnlDKtiuIAw+rAYbdC6FCYUKxNUJ5AFw9?= =?us-ascii?Q?77ce3QKqFMQUjfzIpNCMQdWKcjBSpC8nzqgOqVZ?= =?us-ascii?Q?jvd1aIQqKUstAEuuHnx7rBEJQG5vcD=2FN=2FRdBI0c?= =?us-ascii?Q?KVi3nb05PrZiKuatLEmCA=3D=3D?= To: ruby-dev@ml.ruby-lang.org X-Entity-ID: b/2+PoftWZ6GuOu3b0IycA== Message-ID-Hash: IGXJSPYHNP2GBBEQLOTBNU7IIAOR7CUK X-Message-ID-Hash: IGXJSPYHNP2GBBEQLOTBNU7IIAOR7CUK 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=3A52025=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 mame (Yusuke Endoh). > IMHO if ... is used then *, ** and & should all be forbidden (a SyntaxError at parse time). I agree with this. If you want to do that, you should take it with `def foo(*, **, &)`. I feel that only `&` is acceptable since a block is implicitly passed. But I don't think `*` and `**` make sense inside `def foo(...)`. ---------------------------------------- Feature #19134: ** is not allowed in def foo(...) https://bugs.ruby-lang.org/issues/19134#change-100630 * Author: shugo (Shugo Maeda) * Status: Open * Priority: Normal * Assignee: matz (Yukihiro Matsumoto) * Target version: 3.2 ---------------------------------------- `*` 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/