From debbugs-submit-bounces@debbugs.gnu.org Sun May 21 03:32:29 2023 Received: (at submit) by debbugs.gnu.org; 21 May 2023 07:32:29 +0000 Received: from localhost ([127.0.0.1]:59960 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q0dYL-0000uM-3B for submit@debbugs.gnu.org; Sun, 21 May 2023 03:32:29 -0400 Received: from lists.gnu.org ([209.51.188.17]:44294) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q0alr-0003m9-1y for submit@debbugs.gnu.org; Sun, 21 May 2023 00:34:17 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q0aln-0005ej-Q8 for bug-gnu-emacs@gnu.org; Sun, 21 May 2023 00:34:13 -0400 Received: from relay4-d.mail.gandi.net ([2001:4b98:dc4:8::224]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q0alj-0007iC-SK for bug-gnu-emacs@gnu.org; Sun, 21 May 2023 00:34:11 -0400 Received: (Authenticated sender: zazbrown@zazbrown.com) by mail.gandi.net (Postfix) with ESMTPSA id 37406E0006 for ; Sun, 21 May 2023 04:34:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zazbrown.com; s=gm1; t=1684643644; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type; bh=YFNJmEryfMImw1gccOFh8zSt2SBu0VFb6BDgkNXYvv0=; b=PjYx+mUi1HaMXdR1R5RgGGKuPJv4Ad/04p9qk6i9To+tPtrV7U7z+wABagqPr49be+rJm5 Z8PKuptB88kv+l85qc99Kz82CfxDi3PdlVp1lkRhtkqg+MUnaoSKpgZW6fl02uX1CvqcH4 s773J1QvbZEBnxT/1vkCyer54eYVmSzR92HFGGtIAdHhVA7/VyA8dxkeFDqiTv+ZZwAbbZ 4pSSbe5m5HNOSFHzi3sluC+Zcg/n6SIX92ABxgp3uYHq8L9xm9nOOaQ6Z8BDOJmZiFNR+x JA7ZIEzyY0/HruK47qpEyrWUEwklLAv4sIDli/Emx7FSnDCUGnMPZNVt8vkCTw== Received: by mail-pl1-f172.google.com with SMTP id d9443c01a7336-1ae4baa77b2so34329645ad.2 for ; Sat, 20 May 2023 21:34:03 -0700 (PDT) X-Gm-Message-State: AC+VfDxok5zv33ocZItIGmJZXowzlDjjOfrLghrwG7VC9nVpK5TxSoRE ghVkJV98zjJUbX4yp9JkBiJv7UkdMsnzzLoRUbU= X-Google-Smtp-Source: ACHHUZ4gDTO+YxDyn9KObCtBPh2Xj9HM+NAHTDVV6Q7CvXAPSMCTMlSqkJHD82tD9fE8G71XWamLfkHQYu6AsUcnmtE= X-Received: by 2002:a17:902:e889:b0:1a5:2993:8aa6 with SMTP id w9-20020a170902e88900b001a529938aa6mr8380397plg.63.1684643642281; Sat, 20 May 2023 21:34:02 -0700 (PDT) MIME-Version: 1.0 From: Zaz Brown Date: Sat, 20 May 2023 21:33:51 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: [PATCH] Make forward and backward-to-word arg optional To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset="UTF-8" Received-SPF: softfail client-ip=2001:4b98:dc4:8::224; envelope-from=zazbrown@zazbrown.com; helo=relay4-d.mail.gandi.net X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_SOFTFAIL=0.665, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 21 May 2023 03:32:22 -0400 Cc: dalanicolai@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) (forward-to-word) throws (wrong-number-of-arguments forward-to-word 0) in spite of the doc string stating: > Move forward until encountering the beginning of a word. > With argument, do this that many times. This behaviour is present in Spacemacs 28.2, and has been confirmed by Daniel Nicolai on Emacs 30. It's also evident in the latest source code. The same issue exists for (backward-to-word). But running each command with M-x works with no argument. I'm new to Emacs, so please take this with a grain of salt. Thank you! --- lisp/misc.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git master/lisp/misc.el arg-optional/lisp/misc.el index ca013d5..f97240e 100644 --- a/lisp/misc.el +++ b/lisp/misc.el @@ -166,18 +166,20 @@ is an upper-case character." (upcase-region (point) (progn (forward-char arg) (point))))) ;;;###autoload -(defun forward-to-word (arg) +(defun forward-to-word (&optional arg) "Move forward until encountering the beginning of a word. With argument, do this that many times." (interactive "^p") + (unless arg (setq arg 1)) (or (re-search-forward (if (> arg 0) "\\W\\b" "\\b\\W") nil t arg) (goto-char (if (> arg 0) (point-max) (point-min))))) ;;;###autoload -(defun backward-to-word (arg) +(defun backward-to-word (&optional arg) "Move backward until encountering the end of a word. With argument, do this that many times." (interactive "^p") + (unless arg (setq arg 1)) (forward-to-word (- arg))) ;;;###autoload -- 2.40.1 From debbugs-submit-bounces@debbugs.gnu.org Fri May 26 07:23:46 2023 Received: (at 63626) by debbugs.gnu.org; 26 May 2023 11:23:46 +0000 Received: from localhost ([127.0.0.1]:48975 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2VXt-0008At-KV for submit@debbugs.gnu.org; Fri, 26 May 2023 07:23:45 -0400 Received: from eggs.gnu.org ([209.51.188.92]:47144) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2VXr-0008AX-2C for 63626@debbugs.gnu.org; Fri, 26 May 2023 07:23:43 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2VXl-0002Pl-9U; Fri, 26 May 2023 07:23:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=xLE9R8nvM4Vv8q83GGuTGy+GDELIJl2yheY/9fYuLKM=; b=Gyi8END6eZ+S C6DNqjr1fWvxzgfkHe3KG2iXyddLJvFWirXHkLBbIGgJqv0TIuMW2GDjgpcXx4ZgElD6gJIM1JpED 1ubPP21cQLkyI3qfNJufEAuPZfGRgxkRfm6x+2O7jg1sqmJqlRxiJIBalVRiUamhGAWEM3I0+l6mJ dpz4Sm06eqxDMcYZBPBhej65vRGqPcvhrQZxY1e5jvUwS4+6xdLfndJJeMj2QGZkw+/LwW3SODebY piCuqyBl7G4E4ANWlLWmW1l7JgUMVFhGVLGeOQTPPqdIPPqIIszwrQmDIy5zNH8Sa5nOOy+9zvtoi Tb1u7YmT+iHnt2J1+8AUOw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2VXk-0006mh-PC; Fri, 26 May 2023 07:23:37 -0400 Date: Fri, 26 May 2023 14:24:08 +0300 Message-Id: <83zg5rjpyf.fsf@gnu.org> From: Eli Zaretskii To: Zaz Brown In-Reply-To: (message from Zaz Brown on Sat, 20 May 2023 21:33:51 -0700) Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional References: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63626 Cc: dalanicolai@gmail.com, 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Cc: dalanicolai@gmail.com > From: Zaz Brown > Date: Sat, 20 May 2023 21:33:51 -0700 > > (forward-to-word) throws (wrong-number-of-arguments forward-to-word 0) > in spite of the doc string stating: > > > Move forward until encountering the beginning of a word. > > With argument, do this that many times. > > This behaviour is present in Spacemacs 28.2, and has been confirmed by > Daniel Nicolai on Emacs 30. It's also evident in the latest source code. > > The same issue exists for (backward-to-word). But running each command > with M-x works with no argument. Thank you for your report. Please tell why you think we should allow non-interactive invocation of these functions with no argument. IOW, what exactly is wrong with the current code, and in what situations you have found this to be a problem? From debbugs-submit-bounces@debbugs.gnu.org Sat May 27 03:02:57 2023 Received: (at 63626) by debbugs.gnu.org; 27 May 2023 07:02:58 +0000 Received: from localhost ([127.0.0.1]:51313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2nx3-0003z7-IJ for submit@debbugs.gnu.org; Sat, 27 May 2023 03:02:57 -0400 Received: from eggs.gnu.org ([209.51.188.92]:35988) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2nx1-0003ys-1I for 63626@debbugs.gnu.org; Sat, 27 May 2023 03:02:55 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2nwu-0005rj-CP; Sat, 27 May 2023 03:02:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=HKXIFuKpIzBd2Q8q+Na0BT5cIkIjrXWIHzqa+Q5OZFs=; b=Gi+qqVbLxfe0 tp/0lp4lm1aayvwMgMezCHMweU/xuXrF8n8jtdfhn9GlgIGskReFQ+JKhlhPV0I10lxNi8yx3dER6 F+mpD4DM72oXsijWK4K3Fdp/9j1hRqQHibDiQnvwjuL+HtCldx/PJVbEZoqMNOOIBlaw0N21h24c3 /GDiyNzQTg0qumcu/VCsNwnf3KtAk+skLKTNjxy2zyLjWjiKpt792b8G5feqadCA3O6mxXz3ENkdl er96nkOTOxjgs6FSArlJ7AwRYDceTM0ecdpiqZp+X/ldT38SUVU0xEomUNnpkT1wbpfbUmg2fg+Ye HKVNE6kcZD1DtG3Mdy1Uug==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2nwT-00058M-7a; Sat, 27 May 2023 03:02:48 -0400 Date: Sat, 27 May 2023 10:02:55 +0300 Message-Id: <837csujly8.fsf@gnu.org> From: Eli Zaretskii To: Zaz Brown In-Reply-To: (message from Zaz Brown on Fri, 26 May 2023 12:54:19 -0700) Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional References: <83zg5rjpyf.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63626 Cc: dalanicolai@gmail.com, 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) [Please use Reply All to reply, to keep everyone on the CC list.] > From: Zaz Brown > Date: Fri, 26 May 2023 12:54:19 -0700 > > It's more convenient to be able to use forward-to-word without the > argument. For example, this would allow passing the function > forward-to-word without having to use a lambda. > > Most importantly, though, the current definition of forward-to-word > does not match the doc string. The doc string implies that with no > argument, it goes forward 1 word. And this has already caused > confusion. The doc string says "with argument", most probably meaning "with prefix numeric argument". IOW, it talks about interactive invocation. In any case, the doc string is easy to fix/clarify. But I'm still not convinced we need to change the signature of the function. What are the use cases where you'd want to pass forward-to-word as a function argument to another function? From debbugs-submit-bounces@debbugs.gnu.org Sat May 27 19:54:22 2023 Received: (at 63626) by debbugs.gnu.org; 27 May 2023 23:54:22 +0000 Received: from localhost ([127.0.0.1]:52713 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q33jq-0005xt-3r for submit@debbugs.gnu.org; Sat, 27 May 2023 19:54:22 -0400 Received: from relay9-d.mail.gandi.net ([217.70.183.199]:59339) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2ypY-0005ij-0C for 63626@debbugs.gnu.org; Sat, 27 May 2023 14:39:56 -0400 X-GND-Sasl: zazbrown@zazbrown.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zazbrown.com; s=gm1; t=1685212789; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=y3jhNULk6jnprtU5hxvZwjxvSheS1uZlXx4OdbjaWlQ=; b=TuAw7lI9Qv2f9RGVED8Ekp9BrMZuCOVlm3QcnW7b14PU3+B34Dim266AIdmXdJWgLhqXus 9AWZwpI3+Xjm+q2eebi9IcAx0tGipgxZs7Jh5zKAUyXx/zVkWvSYyH8oJbD96Qv4l1YIol ATBrobR9HCso0hidpy1dnSz8KKw4VwW98f1LyDme+D+kBTxmImB4QSdLaoYZBLr5QWYBXQ 6xOYH3hc8PXp+TFzATo31rqQBugggrIDekOPgSN+kh1I0XF/WRyXEr3Pff82bdN4mUY9fk GHC+t6e5XsacV3aXkHKw+QnVlTyRVCSsUlFf651uXUAzaLtg8MXA8+VC/C4Q4g== Received: by mail.gandi.net (Postfix) with ESMTPSA id 0E7BCFF802 for <63626@debbugs.gnu.org>; Sat, 27 May 2023 18:39:48 +0000 (UTC) Received: by mail-pg1-f174.google.com with SMTP id 41be03b00d2f7-53f70f5ef60so133241a12.1 for <63626@debbugs.gnu.org>; Sat, 27 May 2023 11:39:48 -0700 (PDT) X-Gm-Message-State: AC+VfDx+SyjaVujEyVT0lf7M0Locm4AuLSxFYiUg/rFC8EG5vpAUrXiQ UHc5CPrzBXrtBlJSywRmFl5R712o0OHLbBp/a3w= X-Google-Smtp-Source: ACHHUZ4F4cNIt8+qj3QLC2ZOMx5BKlrozfxpsJ0Tmf3zADx3DyFzTgxk5OrFrdeJGW/E2sIMyWCAtEBq5cnqTMN/Wf0= X-Received: by 2002:a05:6a20:3d10:b0:10b:60c1:2999 with SMTP id y16-20020a056a203d1000b0010b60c12999mr3803851pzi.22.1685212787358; Sat, 27 May 2023 11:39:47 -0700 (PDT) MIME-Version: 1.0 References: <83zg5rjpyf.fsf@gnu.org> <837csujly8.fsf@gnu.org> In-Reply-To: <837csujly8.fsf@gnu.org> From: Zaz Brown Date: Sat, 27 May 2023 11:39:35 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional To: Eli Zaretskii Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 63626 X-Mailman-Approved-At: Sat, 27 May 2023 19:54:21 -0400 Cc: dalanicolai@gmail.com, 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) On Sat, May 27, 2023 at 12:02=E2=80=AFAM Eli Zaretskii wrote= : > But I'm still not convinced we need to change the signature of the > function. What are the use cases where you'd want to pass > forward-to-word as a function argument to another function? I can't think of a good example and wasn't able to find an example of a forward-to-word lambda on GitHub code search. So perhaps I'm mistaken that this would be useful. I'll have to leave that discussion to those who are more familiar with Emacs and Lisp. From debbugs-submit-bounces@debbugs.gnu.org Sun May 28 01:16:26 2023 Received: (at 63626) by debbugs.gnu.org; 28 May 2023 05:16:26 +0000 Received: from localhost ([127.0.0.1]:52976 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q38lW-00009G-04 for submit@debbugs.gnu.org; Sun, 28 May 2023 01:16:26 -0400 Received: from eggs.gnu.org ([209.51.188.92]:41382) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q38lU-000092-6I for 63626@debbugs.gnu.org; Sun, 28 May 2023 01:16:24 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q38lN-0000jI-Na; Sun, 28 May 2023 01:16:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=aC+njOUh0gG5lMsSC/+R6/rSfUbLiruYPx8n78UpvmE=; b=OthYPqmztHCrSUrCOsaN zhaBRs5DrYeNvOMSR1B+qFztY5zJdsk6dlh47NkeFxQ34ezGs/FOH8zwqBvtQFf2Ti3YhMc2+w/sT hxXdaRwriXO5K2cJ8j8uXi4pFjkQTz7kOt3Bcvi6IH57sbucFzehxm6oCruUcEpDqcqJpt45kNwcS mMcLPgYiJHFuzZWzP+fsM0uBDWF2oamzX84KCE2ckd0DvymzqKUsLeCvInAHIPRLtaha8prT3Ajuk Qn4wcnXMK2Xo2DOSXuzo6E8yJ/uNZPpftwm0kUjN2jAjFVN5HAMWpilGY8LpXl6Y+ov5jkeQPZXKU Ople4/mIMtKguA==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q38lN-0006jY-32; Sun, 28 May 2023 01:16:17 -0400 Date: Sun, 28 May 2023 08:16:53 +0300 Message-Id: <83ttvxhw6y.fsf@gnu.org> From: Eli Zaretskii To: Zaz Brown In-Reply-To: (message from Zaz Brown on Sat, 27 May 2023 11:39:35 -0700) Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional References: <83zg5rjpyf.fsf@gnu.org> <837csujly8.fsf@gnu.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63626 Cc: dalanicolai@gmail.com, 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Zaz Brown > Date: Sat, 27 May 2023 11:39:35 -0700 > Cc: dalanicolai@gmail.com, 63626@debbugs.gnu.org > > On Sat, May 27, 2023 at 12:02 AM Eli Zaretskii wrote: > > But I'm still not convinced we need to change the signature of the > > function. What are the use cases where you'd want to pass > > forward-to-word as a function argument to another function? > > I can't think of a good example and wasn't able to find an example of > a forward-to-word lambda on GitHub code search. So perhaps I'm > mistaken that this would be useful. I'll have to leave that > discussion to those who are more familiar with Emacs and Lisp. Thanks. Does anyone else here have an opinion on this changeset? From debbugs-submit-bounces@debbugs.gnu.org Mon May 29 11:24:34 2023 Received: (at 63626) by debbugs.gnu.org; 29 May 2023 15:24:34 +0000 Received: from localhost ([127.0.0.1]:58909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3ejZ-0002VL-LI for submit@debbugs.gnu.org; Mon, 29 May 2023 11:24:33 -0400 Received: from mail-wm1-f48.google.com ([209.85.128.48]:58628) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3ejX-0002V5-L7 for 63626@debbugs.gnu.org; Mon, 29 May 2023 11:24:32 -0400 Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-3f6e68cc738so22578635e9.1 for <63626@debbugs.gnu.org>; Mon, 29 May 2023 08:24:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685373866; x=1687965866; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Bc70R+GRoHwvV2hKMRggjVtIOmyrEqxuVEgzGRZk7P0=; b=Mnf4SYm57QryHWv1uRqaRPDakgKmInw5WrcFSeStg3MFlkpv4+a34NYA3wHAujx2Yi mfKtcgRvGDUZ9CsVsdlnro31UOuw5UGc7Co7Y6tP+uT/VSG1Cmf9RzutWX7HHiHhi2Mc 3bP8C2huOrFqGjyON0rqODiidla22gd8wm9K7KevQKpJTyEwgkBNkka3gduPhZuuToH0 z04cAAFglnOXG/pyLcEBaY7vctWMlHLKFG76hXqLxy1HHqs1jXXikdc+0CWZk4JIU258 Z2fVkqC2Vum3kuqTtVU6Y9RITYkVNYfjS6/EMpoc4YmxHwVD92vPs5L62OZrxFJBQuAN DToA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685373866; x=1687965866; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Bc70R+GRoHwvV2hKMRggjVtIOmyrEqxuVEgzGRZk7P0=; b=h4TFOJKRhCKVptvTa4xQCzI8GBqkd3S+xyEv5eFfS6+kcZM07YW73eW6lMxQRJol15 6YngUuYNRVvTuPBYZ0jaNxRJ3BEcjv2xeOec3sJQGjNgbPH8pJa9LkxtHTmeM7/jaJW0 62a/+06nY+t7vD9f6jM75MZcX9VCMK3bsUJqI8FALgyrYmdnIkUOEjnft7KR5ooCOvgC 3ZzfS4FLA8nlTZjZDTEuOFUXoySS1EsFf8v5JCXRY6u0tMzudBR9G90QCgL4at0YT/8S 44NcegHfrIxVxgc/BtbdXsQY39Zn8mUbABJlk0xTdUB15+VPI6iLpvgBoE9GcufynID7 PifQ== X-Gm-Message-State: AC+VfDzmoG1Hyqnyf14V9yLEAxaC/rujFcMCOJfNRlumdcbSLBxO8dFO pCbC9XmWsL62SkQyaJJsAvlbZFry3sJBqE4pRPnB8Q8UZ4kh7g== X-Google-Smtp-Source: ACHHUZ7iZq91Jt9g75uuPlR1aYzwIaHKo7TM+8FVGE4r0adHOj5oV/wh+3B7ECU7FdvTCfQjSq1smEj68ho2olk6JYw= X-Received: by 2002:a7b:c449:0:b0:3f6:7e6:44ea with SMTP id l9-20020a7bc449000000b003f607e644eamr9750698wmi.18.1685373865663; Mon, 29 May 2023 08:24:25 -0700 (PDT) MIME-Version: 1.0 References: <83zg5rjpyf.fsf@gnu.org> <837csujly8.fsf@gnu.org> <83ttvxhw6y.fsf@gnu.org> In-Reply-To: <83ttvxhw6y.fsf@gnu.org> From: dalanicolai Date: Mon, 29 May 2023 17:24:14 +0200 Message-ID: Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional To: Eli Zaretskii Content-Type: multipart/alternative; boundary="00000000000093a11c05fcd6aeb6" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 63626 Cc: Zaz Brown , 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --00000000000093a11c05fcd6aeb6 Content-Type: text/plain; charset="UTF-8" I have no opinion about how this 'should work'. I was just confused by the docstring, and I assumed from the docstring, that the intention was for the argument to be optional like in forward-word/line (the docstring does not say that this command is meant for interactive use only). My idea was just to report this very low priority issue about the 'confusing' docstring (and ask if maybe that argument was intended to be optional). Here is the motive for this patch. It is used in an evil function, so I guess we could just have used `evil-forward-WORD-begin` instead, and it is not necessary to change the `forward-to-word` function. --00000000000093a11c05fcd6aeb6 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I have no opinion about how this 'should work'= ;.
I was just confused by the docstring, and I assumed from t= he docstring,
that the intention was for the argument to be optio= nal like in forward-word/line
(the docstring does not say that th= is command is meant for interactive use only).

My = idea was just to report this very low priority issue about the 'confusi= ng' docstring
(and ask if maybe that argument was intended to= be optional).

Here is the motive for this patch. It is used in= an evil function, so I guess we could
just have used `evil-forwa= rd-WORD-begin` instead, and it is not necessary to change
the `fo= rward-to-word` function.


--00000000000093a11c05fcd6aeb6-- From debbugs-submit-bounces@debbugs.gnu.org Mon May 29 13:07:46 2023 Received: (at 63626) by debbugs.gnu.org; 29 May 2023 17:07:46 +0000 Received: from localhost ([127.0.0.1]:59038 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3gLS-0001rO-0o for submit@debbugs.gnu.org; Mon, 29 May 2023 13:07:46 -0400 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:55187) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3gLQ-0001qs-3k for 63626@debbugs.gnu.org; Mon, 29 May 2023 13:07:44 -0400 X-GND-Sasl: juri@linkov.net X-GND-Sasl: juri@linkov.net X-GND-Sasl: juri@linkov.net X-GND-Sasl: juri@linkov.net Received: by mail.gandi.net (Postfix) with ESMTPSA id E10521BF204; Mon, 29 May 2023 17:07:36 +0000 (UTC) From: Juri Linkov To: dalanicolai Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional In-Reply-To: (dalanicolai@gmail.com's message of "Mon, 29 May 2023 17:24:14 +0200") Organization: LINKOV.NET References: <83zg5rjpyf.fsf@gnu.org> <837csujly8.fsf@gnu.org> <83ttvxhw6y.fsf@gnu.org> Date: Mon, 29 May 2023 19:46:59 +0300 Message-ID: <86wn0r6q7s.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 63626 Cc: Eli Zaretskii , Zaz Brown , 63626@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > I have no opinion about how this 'should work'. > I was just confused by the docstring, and I assumed from the docstring, > that the intention was for the argument to be optional like in > forward-word/line Aren't all forward-like commands more permissive and allow their arg to be optional? It looks like the standard signature, e.g.: (defun forward-page (&optional count) (interactive "p") (or count (setq count 1)) (defun forward-paragraph (&optional arg) (interactive "^p") (or arg (setq arg 1)) (defun forward-sentence (&optional arg) (interactive "^p") (or arg (setq arg 1)) ... From debbugs-submit-bounces@debbugs.gnu.org Wed May 31 09:15:48 2023 Received: (at 63626-done) by debbugs.gnu.org; 31 May 2023 13:15:48 +0000 Received: from localhost ([127.0.0.1]:35085 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4Lg3-00005t-I1 for submit@debbugs.gnu.org; Wed, 31 May 2023 09:15:47 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50126) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4Lfy-00005c-1K for 63626-done@debbugs.gnu.org; Wed, 31 May 2023 09:15:45 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4Lfq-0002hG-Tk; Wed, 31 May 2023 09:15:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=oesuyeETDuT8CUk+1e5A6SPaY5TQlDMy6UYPYWhfha8=; b=krlP/WHk2jQt VcRCPh0qBNEsOu7hyBUuDp0t+nCk/FU9J+byP7z7nVt8rtjmMbCEedvQtNH92PT1lZX5kll6AYYSw jnCM1ZWhmhei0srhsrdp5qGMYRaTS/kuxrcuT0mB92jf72umo3BBzKoeZYxf+zIeNdrC3vZuvXmAa CI+ngecbRNVk7Ra8s1QZKGeUeK1mCQl6GGTmx1KOv6IS/IM1K2KsogDqx14zzY8C+wnQMLi96ZDx1 LAOWWdLqeLvcX4R7xVnLLhreLgeU/K24rPJD24gNbdMD6QfKIKLOl0ozi2G7PtNjVigOBeffxVZSz fpiyzao4Gry+rjK1KOyFwQ==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4LfV-0001Wo-Vj; Wed, 31 May 2023 09:15:33 -0400 Date: Wed, 31 May 2023 16:15:57 +0300 Message-Id: <838rd4fxpu.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86wn0r6q7s.fsf@mail.linkov.net> (message from Juri Linkov on Mon, 29 May 2023 19:46:59 +0300) Subject: Re: bug#63626: [PATCH] Make forward and backward-to-word arg optional References: <83zg5rjpyf.fsf@gnu.org> <837csujly8.fsf@gnu.org> <83ttvxhw6y.fsf@gnu.org> <86wn0r6q7s.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63626-done Cc: zazbrown@zazbrown.com, dalanicolai@gmail.com, 63626-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: Eli Zaretskii , Zaz Brown , > 63626@debbugs.gnu.org > Date: Mon, 29 May 2023 19:46:59 +0300 > > > I have no opinion about how this 'should work'. > > I was just confused by the docstring, and I assumed from the docstring, > > that the intention was for the argument to be optional like in > > forward-word/line > > Aren't all forward-like commands more permissive and allow their arg > to be optional? It looks like the standard signature, e.g.: Thanks for the feedback, all of you. I've now installed those changes on the master branch, and I'm therefore closing this bug. From unknown Sat Aug 16 13:46:04 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 29 Jun 2023 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator