From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#41727: 26.3; Doc of `define-minor-mode' and minor-mode commands Date: Sat, 6 Jun 2020 09:45:46 -0700 (PDT) Message-ID: <9d7f8447-1c0b-46db-a40c-c1ed2a398c46@default> References: <963d4189-17dc-4f4e-9993-0335fa271e50@default> <83k10kafha.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="37366"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 41727@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jun 06 19:56:25 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jhd3Q-0009dQ-VO for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 06 Jun 2020 19:56:25 +0200 Original-Received: from localhost ([::1]:58196 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jhd3Q-00063q-1B for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 06 Jun 2020 13:56:24 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52936) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jhd2h-0004xz-UJ for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2020 13:55:39 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40854) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jhd2h-0003sN-KJ for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2020 13:55:39 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jhbxK-0004nY-1T for bug-gnu-emacs@gnu.org; Sat, 06 Jun 2020 12:46:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 06 Jun 2020 16:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41727 X-GNU-PR-Package: emacs Original-Received: via spool by 41727-submit@debbugs.gnu.org id=B41727.159146195918436 (code B ref 41727); Sat, 06 Jun 2020 16:46:02 +0000 Original-Received: (at 41727) by debbugs.gnu.org; 6 Jun 2020 16:45:59 +0000 Original-Received: from localhost ([127.0.0.1]:52347 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jhbxH-0004nI-Ap for submit@debbugs.gnu.org; Sat, 06 Jun 2020 12:45:59 -0400 Original-Received: from aserp2120.oracle.com ([141.146.126.78]:39664) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jhbxF-0004n4-Qq for 41727@debbugs.gnu.org; Sat, 06 Jun 2020 12:45:58 -0400 Original-Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 056GhRHw074189; Sat, 6 Jun 2020 16:45:51 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=4lFdr9i3ygUBR1f+9zxsAri3tYj09JAsFBzpaMxsBME=; b=pGdSstJN/HVsyoPKsz5DXahlaYFAgPVwQnbQOXnFpv119r5XMcqZE3OA0NCsErjheGYG JtdYqMPc/upe3+hRV3z6ROaoaKV1aI+ci9nQP8mbM2Zp2YlXVlnqhKzlRxnIUf8kl9/G jA7Z2hfjTxScl6dNZzR1bHfBpTrRgWCVTyQ2nSYtiF2ijxc5op4ks6BXMzpRcUqBJF19 8hNVASEo764OZqUygZRXMj+FoEj4/0XMAajMPWqIwXO0GOgOdPSJ3tYU9Z2nWg9G8AOZ 4uX5pys1kA5ujORYe46JyJ2QUSg0g3/ITMz9RWetWxinY1z5+1ALViK+lvE5KmyZxQex Lg== Original-Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by aserp2120.oracle.com with ESMTP id 31g33ksfc3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Sat, 06 Jun 2020 16:45:51 +0000 Original-Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 056GdU1v191787; Sat, 6 Jun 2020 16:45:51 GMT Original-Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userp3030.oracle.com with ESMTP id 31g08r2qr9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 06 Jun 2020 16:45:51 +0000 Original-Received: from abhmp0011.oracle.com (abhmp0011.oracle.com [141.146.116.17]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 056GjoLj004824; Sat, 6 Jun 2020 16:45:50 GMT In-Reply-To: <83k10kafha.fsf@gnu.org> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.5005.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9644 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=999 suspectscore=0 bulkscore=0 adultscore=0 spamscore=0 malwarescore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2004280000 definitions=main-2006060132 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9644 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 adultscore=0 spamscore=0 cotscore=-2147483648 malwarescore=0 phishscore=0 mlxscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 priorityscore=1501 mlxlogscore=999 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2004280000 definitions=main-2006060132 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:181622 Archived-At: > > The doc needs improvement when describing calling the mode from Lisp. > > > > 1. The doc string of `define-minor-mode' says this: > > > > When called from Lisp, the mode command toggles the mode if the > > argument is `toggle', disables the mode if the argument is a > > non-positive integer, and enables the mode otherwise (including if > > the argument is omitted or nil or a positive integer). >=20 > It actually says this: > Interactively with no prefix argument, it toggles the mode. > A prefix argument enables the mode if the argument is positive, > and disables it otherwise. >=20 > Yes, and? The point was about what the doc says about a call from Lisp. > > 3. The Elisp manual doc says this (node `Defining Minor Modes'): > > > > From Lisp, an argument of 'toggle' toggles the mode, whereas an > > omitted or 'nil' argument enables the mode. >=20 > It actually says this: > The toggle command takes one optional (prefix) argument. If called > interactively with no argument it toggles the mode on or off. A > positive prefix argument enables the mode, any other prefix > argument disables it. > > Yes, and? The point was about what the doc says about a call from Lisp. The bug report doesn't find fault with the description of the interactive behavior. And my follow-up message suggests text for the doc string that I think is accurate and complete, and it improves the description of the interactive handling as well. The bug report is about the content/message/info, though, not the wording. If you don't like the wording of my suggestion, some other wording that provides as accurate and complete a description will be fine. Thx. > Are you reading obsolete docs? I'm reading the 26.3 docs, as suggested by the report: In GNU Emacs 26.3 (build 1, x86_64-w64-mingw32) of 2019-08-29 Repository revision: 96dd0196c28bc36779584e47fffcca433c9309cd Windowing system distributor `Microsoft Corp.', version 10.0.18362 Configured using: `configure --without-dbus --host=3Dx86_64-w64-mingw32 --without-compress-install 'CFLAGS=3D-O2 -static -g3''