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)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id AA0721F601 for ; Thu, 15 Dec 2022 12:27:10 +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="W8oTCyum"; dkim-atps=neutral Received: from nue.mailmanlists.eu (localhost [127.0.0.1]) by nue.mailmanlists.eu (Postfix) with ESMTP id 2A7FC7F09C; Thu, 15 Dec 2022 12:26:55 +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=W8oTCyum; 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 834F67F03C for ; Thu, 15 Dec 2022 12:26:49 +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=isd3/hzspk5PxAfI4hofaWIasn0c2VomDGqne/+fC0I=; b=W8oTCyumKYGnzjvSv7rJURFhd+smibeMfbAwjmzWFM5UpJkOIZPS67xIzff/EOK2LnYx UcILlj0L/5Pxpa3e/STC2Qgswm2YvpoGXpu9sOysE9V/PQTHgJmCs/RjoryWDcZx6M2yUl C17kLK2jprKug976INDMHOjh2YEsakuRgj0pVXwegZqfuFZxKFg+PiBoSCPZqmaqlCPa4y cubbXzHg1RdKS7AkmLoxo+9qtdA0QmGa9KMTLcsCV5sbGQUPl/XRgijzsmdX/aIwU3aAvD 8jQy6i3m/3Jw/IgbqS7VFIC7I2VkDVH+K3Z45QRJbeFa6YnEqtQl/mCmXzxmWz9g== Received: by filterdrecv-6b9548745c-hc4x9 with SMTP id filterdrecv-6b9548745c-hc4x9-1-639B1288-8 2022-12-15 12:26:48.134611097 +0000 UTC m=+2380716.699406668 Received: from herokuapp.com (unknown) by geopod-ismtpd-5-4 (SG) with ESMTP id T5U4TCmiS-u9t_nBEixwGA for ; Thu, 15 Dec 2022 12:26:48.094 +0000 (UTC) Date: Thu, 15 Dec 2022 12:26:48 +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: 87709 X-SG-EID: =?us-ascii?Q?o0C=2FsDUd4ZFGiDZCTbvVjqibxcpCfydz4lwnBQWyXZ+Plw=2FfhrG0CQPbrktOPX?= =?us-ascii?Q?NfKIrb7bilCwkXET66DNxoL175MSPd01efg5gvu?= =?us-ascii?Q?mVC6U242IF2vkG7GDbt2CxNTMB2um=2FYBpe7jdJw?= =?us-ascii?Q?QZ81JJfrK1pb2f5JKfPEjvB8tyrJD8pf1dzje1I?= =?us-ascii?Q?IJq+VzVxYPhlJYYQoadLutT6B3P+MVb=2FB5CCJZX?= =?us-ascii?Q?=2FnZlP2hiCe4pflrpS0elADWPNIuxEH8m6eFz3=2Fo?= =?us-ascii?Q?K9VEZKVxkydx=2Fw2+27Xwg=3D=3D?= To: ruby-dev@ml.ruby-lang.org X-Entity-ID: b/2+PoftWZ6GuOu3b0IycA== Message-ID-Hash: YLUQQCOZPUERMR4HOTSICWHYNFEGWAAB X-Message-ID-Hash: YLUQQCOZPUERMR4HOTSICWHYNFEGWAAB 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=3A52027=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). mame (Yusuke Endoh) wrote in #note-12: > I feel that only `&` is acceptable since a block is implicitly passed. But I don't think `*` and `**` make sense inside `def foo(...)`. Speaking of implicity of blocks, `def f; g(&); end` causes a syntax error, so it may be better to allow it, or disallow `def f(...); g(&); end` in the future versions. Anyway, I've fixed the behavior of `...` as described in #note-9. ---------------------------------------- Feature #19134: ** is not allowed in def foo(...) https://bugs.ruby-lang.org/issues/19134#change-100678 * Author: shugo (Shugo Maeda) * Status: Closed * 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/