From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: dalanicolai@gmail.com Newsgroups: gmane.emacs.bugs Subject: bug#49843: 28.0.50; Error in docstring after using define-globalized-minor-mode Date: Tue, 03 Aug 2021 06:51:35 +0200 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13298"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Evolution 3.40.3 (3.40.3-1.fc34) To: 49843@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 03 06:52:11 2021 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 1mAmPS-0003Hy-Cq for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 03 Aug 2021 06:52:10 +0200 Original-Received: from localhost ([::1]:42670 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mAmPQ-0003r7-DP for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 03 Aug 2021 00:52:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34622) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mAmPL-0003qs-16 for bug-gnu-emacs@gnu.org; Tue, 03 Aug 2021 00:52:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56327) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mAmPK-00080x-QF for bug-gnu-emacs@gnu.org; Tue, 03 Aug 2021 00:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mAmPK-00030X-KR for bug-gnu-emacs@gnu.org; Tue, 03 Aug 2021 00:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: dalanicolai@gmail.com Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 03 Aug 2021 04:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 49843 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.162796630211534 (code B ref -1); Tue, 03 Aug 2021 04:52:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 3 Aug 2021 04:51:42 +0000 Original-Received: from localhost ([127.0.0.1]:39640 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mAmP0-0002zy-9G for submit@debbugs.gnu.org; Tue, 03 Aug 2021 00:51:42 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:58388) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mAmOy-0002zr-Oy for submit@debbugs.gnu.org; Tue, 03 Aug 2021 00:51:41 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34546) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mAmOy-0003pz-GO for bug-gnu-emacs@gnu.org; Tue, 03 Aug 2021 00:51:40 -0400 Original-Received: from mail-ej1-x633.google.com ([2a00:1450:4864:20::633]:33369) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mAmOw-0007fW-MS for bug-gnu-emacs@gnu.org; Tue, 03 Aug 2021 00:51:40 -0400 Original-Received: by mail-ej1-x633.google.com with SMTP id hs10so25739421ejc.0 for ; Mon, 02 Aug 2021 21:51:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:subject:from:to:date:user-agent:mime-version :content-transfer-encoding; bh=khhJ4PoMSMTXu1ugYN2cFhEYoYYmG+sxlKYS+43Kink=; b=migN0VkGfM/A5ZHGvORVDYhIboCckkJAqIPTQntSa6Du5ttm/rd8MQTDj8sMft7J4g Wwp+b4gWkWKQ6tjVh+MfdVk/67C6RxAwGRiG/GyMx+lac5AcnOeUjthfU0mictkSCajx +qA6qNrjAJSCOKxKV/O16KAivTsmP+V6s4EGd7o7YLQCxmWVfVSuLf6sZ8rns6qtRtsv REbEAeyDzvymn3/uGtIJMMa1SqAJQkJtuLPv+fLUCtwGglk4oSXuQa3rMFpUt7OkddUu W/gl6p1sxlgpXFMOe4+Yr8oSPuGl70iblGigHN9Ug9hDywrhal711bxJ6IqFbmoyLmBU QU5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:user-agent :mime-version:content-transfer-encoding; bh=khhJ4PoMSMTXu1ugYN2cFhEYoYYmG+sxlKYS+43Kink=; b=rGTq10qjhh3movs5R3I+hYNO51vhg6lNWLNGPNoUh7ZfkCvPou1iWct44elKUGwzsV e7eGns/mZXnspLE0+U73NCi5colPSFe1cM7f2FrT5da4SCl8w3EnzeytS3WerY7VXn8/ ixtqymufBdm6pgaO6GYXKQy1eBQUGqGtwzTczkqG6bfFHeMO31dQunvx457RKahGXNBD y8kkrXV9FUpJ4nTzn7oHAho6EhZrmy2uNQIlz+jsaM9NEg+HYjL2uDPhPeuGP+P8a5gr P1BgPmbj35smPQwfo2OGd6GnBuPci7E67AZALf8EbAPkAcHcJgwuCnCsMEEdELBQRMlN Fn2g== X-Gm-Message-State: AOAM531ra4qukj8Dp20oTXoD9/DFBx4j72P94KszbYDa42/3tviSfQLX BH0JKDxnEUKsVeplFYEPLx/ZKELCVc8hyA== X-Google-Smtp-Source: ABdhPJyJ7mMXMVSnupXiPEyR7A/IrY71SbHYIyAH77cMW+8KgyuGVRjCPifvxzLkLyLG8lVQ2JZH2w== X-Received: by 2002:a17:907:629c:: with SMTP id nd28mr18529981ejc.403.1627966296883; Mon, 02 Aug 2021 21:51:36 -0700 (PDT) Original-Received: from [192.168.3.11] (86-90-107-231.fixed.kpn.net. [86.90.107.231]) by smtp.gmail.com with ESMTPSA id ks26sm5557187ejb.58.2021.08.02.21.51.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Aug 2021 21:51:36 -0700 (PDT) Received-SPF: pass client-ip=2a00:1450:4864:20::633; envelope-from=dalanicolai@gmail.com; helo=mail-ej1-x633.google.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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:211087 Archived-At: When creating a global minor mode using `define-globalized-minor-mode', some explanation in the default created docstring for the new global minor mode reads (e.g. for `global-display-fill-column-indicator-mode') : "With prefix ARG, enable Global Display-Fill-Column-Indicator mode if ARG is positive; otherwise, disable it.  If called from Lisp, enable the mode if ARG is omitted or nil." So it says that, when called from lisp, the mode is not enabled if any ARG except nil is passed. It is easy to verify that that statement is wrong by evaluating (global-display-fill-column-indicator-mode 'with-any-non-negative-number-argument) directly after starting emacs with -Q flag. Also the argument 'toggle can be uses for toggling it. It looks like the docstring could just copy the explanation about behavior when calling from lisp from the `define-minor-mode' docstring. (I am not sure if the `define-globalized-minor-mode' macro adds any logic for the behavior for (de)activating the global mode; I think it only adds logic for the behavior i.c.w. its non-global mode, for which the explanation is not clear to me also b.t.w., but I am still trying to track down how that behaves exactly). In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.25, cairo version 1.16.0)  of 2021-02-18 built on daniel-fedora Repository revision: 185121da6978553d538d37d6d0e67dc52e13311f Repository branch: feature/native-comp Windowing system distributor 'The X.Org Foundation', version 11.0.12011000 System Description: Fedora 34 (Workstation Edition) Configured using:  'configure --with-nativecomp' Configured features: CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PNG RSVG SOUND THREADS TIFF TOOLKIT_SCROLL_BARS X11 XDBE XIM XPM GTK3 ZLIB Important settings:   value of $LANG: en_US.UTF-8   value of $XMODIFIERS: @im=none   locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect:   global-display-fill-column-indicator-mode: t   display-fill-column-indicator-mode: t   tooltip-mode: t   global-eldoc-mode: t   eldoc-mode: t   electric-indent-mode: t   mouse-wheel-mode: t   tool-bar-mode: t   menu-bar-mode: t   file-name-shadow-mode: t   global-font-lock-mode: t   font-lock-mode: t   blink-cursor-mode: t   auto-composition-mode: t   auto-encryption-mode: t   auto-compression-mode: t   line-number-mode: t   transient-mark-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs rfc822 mml mml-sec epa derived epg epg-config gnus-util rmail rmail-loaddefs auth-source cl-seq eieio eieio-core eieio-loaddefs password-cache json map cl-macs text-property-search mm-decode mm- bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils pp easy-mmode display-fill-column-indicator time-date subr-x cl-extra seq byte-opt gv bytecomp byte-compile cconv cl-print hl-line thingatpt help-fns radix-tree help-mode easymenu cl-loaddefs cl-lib iso-transl tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp- mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button loaddefs faces cus-face pcase macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit x multi-tty make-network-process nativecomp emacs) Memory information: ((conses 16 80391 7027)  (symbols 48 7063 0)  (strings 32 22435 1869)  (string-bytes 1 727500)  (vectors 16 13456)  (vector-slots 8 294714 10744)  (floats 8 35 31)  (intervals 56 239 0)  (buffers 992 12))