From unknown Wed Jun 25 00:21:42 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#50801 <50801@debbugs.gnu.org> To: bug#50801 <50801@debbugs.gnu.org> Subject: Status: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" Reply-To: bug#50801 <50801@debbugs.gnu.org> Date: Wed, 25 Jun 2025 07:21:42 +0000 retitle 50801 28.0.50; Emacs manual about file variables doesn't mention th= at major modes shouldn't end in "-mode" reassign 50801 emacs submitter 50801 Daniel Mart=C3=ADn severity 50801 normal tag 50801 fixed thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 25 09:39:56 2021 Received: (at submit) by debbugs.gnu.org; 25 Sep 2021 13:39:56 +0000 Received: from localhost ([127.0.0.1]:60456 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mU7uG-0004hD-80 for submit@debbugs.gnu.org; Sat, 25 Sep 2021 09:39:56 -0400 Received: from lists.gnu.org ([209.51.188.17]:48136) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mU7uE-0004h5-M0 for submit@debbugs.gnu.org; Sat, 25 Sep 2021 09:39:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33414) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mU7uE-0004CL-FB for bug-gnu-emacs@gnu.org; Sat, 25 Sep 2021 09:39:54 -0400 Received: from sonic313-20.consmr.mail.ir2.yahoo.com ([77.238.179.187]:43305) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mU7uB-0004uc-Ov for bug-gnu-emacs@gnu.org; Sat, 25 Sep 2021 09:39:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.es; s=s2048; t=1632577188; bh=+6mwVwj0kGttBfeC8FqWmAleSP8ONG8JJTw231IGnbY=; h=From:To:Subject:Date:References:From:Subject:Reply-To; b=k29rC6g1SHcEC5FcfUPRa037oJsrqcNNy3b+zvfoAlb5eYYlE3CmYVolLxqj9cHLwv2BSfvxRlioprlSExcyGqIRY3oiLOwCHolUU/iCoo/59wt0rfAQoZ0FxA4R7kdgEpMWbfN+bCaJopttzOpF99XlMCLW8LHCJqMlzJZYNcLzqpuQFJ1AfA//Sc7VcsVXCuDn4rhz0CwFspP+R748F4WSlYDT0CM38oFkav2O9SZnsNkxH7iZhKBxeYJUb2wD3kXR570RtYwiA9sxqALrEJ7H89hz61qyZgomQUzvlstQk6as0/MJKVrDh4QeUzYGRib3yO+gV+/hL8WuG9ENgA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1632577188; bh=1GYrm4ruviWNaEQUpcPXClh1uBXq5Yyg0+IFKcqvZEo=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=hBLLt3c8Hilooq7NwiK0CuvK6KGn2zPyayApkIc/RaZCztz04pge8G4AHU/NTEGpLlRvjJPZJiIFGt53XwQy3hkIKWYm1a06MR1JphbTwUKH4ww4lXOSjq+APER254A/aBhN5roruBr1lXGbOa+DALz1mSVv8obhJfA3NmyQaImlDE9srHYHOErm45YoSE6H1q8cItahC07FnFu04W992p/IZ2zW3mt4UpIqMIGM7oEHLemRX9t4Gr02wlY1MZH+uljplepBo9eZFcVHCOrIfQPe6KcGdUfAMT2WZJ5DfjxNrp1D+GvHuh7f0H2hwBirDyU0KGFyhtjUed5e0QmThA== X-YMail-OSG: H.wDfyIVM1lQ0jWD2x1DLjSDf1OrhyjXvps7ix5.BDgFq9Pj347WTGTGV7f7E8r DtUjOi0hk220_TmbX4ulZGHDRBV4zw_GRxVnZVBjv_GRwhuR7C6KfYFUjSlmnPz6UUpWcK2KVW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bAce.0LeVZnPJEpaJ_o8XZVI- X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic313.consmr.mail.ir2.yahoo.com with HTTP; Sat, 25 Sep 2021 13:39:48 +0000 Received: by kubenode530.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID fd6894ed26e6ed6eacb8f126524721d1; Sat, 25 Sep 2021 13:39:46 +0000 (UTC) From: =?utf-8?Q?Daniel_Mart=C3=ADn?= To: bug-gnu-emacs@gnu.org Subject: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" Date: Sat, 25 Sep 2021 15:39:45 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain References: X-Mailer: WebService/1.1.19043 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Content-Length: 1086 Received-SPF: pass client-ip=77.238.179.187; envelope-from=mardani29@yahoo.es; helo=sonic313-20.consmr.mail.ir2.yahoo.com X-Spam_score_int: -4 X-Spam_score: -0.5 X-Spam_bar: / X-Spam_report: (-0.5 / 5.0 requ) BAYES_05=-0.5, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit 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.4 (--) I'm reviewing the manuals for the upcoming Emacs 28 and I have a couple of minor suggestions for node "49.2.4.1 Specifying File Variables": The node doesn't explictly mention the crucial information that in 'mode: MODENAME' 'MODENAME' must not end in "-mode". It's true that there's an example down there that says "mode: Lisp", so users may infer that you don't need to spell the major mode with "-mode", but I thought it may be better to be explicit about in the manual. Another suggestion I have is that the manual doesn't mention that something like "-*- C++ -*-" (that is, omitting the "mode" keyword) is also supported. Many free software projects have traditionally been using "-* C++ -*" in their C++ header files to make Emacs distinguish them from plain C files. See also src/epaths.in in the Emacs repository, among others. I see this used by Jim Blandy since 1992 at least, but I don't really know if a) it's really a stable way to declare a file-local mode, and we may lack the historical info to answer that, and b) it's worth mentioning it in the manual. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 25 13:46:21 2021 Received: (at 50801) by debbugs.gnu.org; 25 Sep 2021 17:46:21 +0000 Received: from localhost ([127.0.0.1]:34632 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUBki-0007cM-T9 for submit@debbugs.gnu.org; Sat, 25 Sep 2021 13:46:21 -0400 Received: from mail-pl1-f176.google.com ([209.85.214.176]:34678) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUBkg-0007c7-NO for 50801@debbugs.gnu.org; Sat, 25 Sep 2021 13:46:19 -0400 Received: by mail-pl1-f176.google.com with SMTP id a7so8777956plm.1 for <50801@debbugs.gnu.org>; Sat, 25 Sep 2021 10:46:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:in-reply-to:references:user-agent :mime-version:date:message-id:subject:to:cc :content-transfer-encoding; bh=M8nNDqymnfvYIqk4zK0pyIGxSwY40uKKNGc4IfLxp5M=; b=suTGpFTyxUQWYUhuLg9kpp9mruXKTW9QHr9c/62iV7YRU+9QthEDLACWJaX9R4MWlL CsCgPSFCRMuFWQ+F04ICNAmilnyPqTWG0wVOEuuF8seXVLAMsLTZqtPOqVCC621HA8To ObgAyMfQ1+2CdgTA9ynND8O3aeDer875GnuEngkioL6CVm87TPmDSB6toMVNfJz+aC1n ko8UmZeuN/g+r1OVO6JnWwBDLhnMfYEYjYYb8yjarMzKMv93NmBPQ/ALETphkLhACPrN VdwbD3bvIQE9lQNYNCI2TuI/Aqsy8dnuVVFmaObArdKX/dazFdQ4Kf+H2vEsm0T9YIBF UTjg== X-Gm-Message-State: AOAM531MGR1LUcU24VRikwP0uWncd6LpLm88IpTv9wbb5ZnrCy4D3SAl YP99Cjjx51P/F+J/EMCLMFWB32sQkW8bdyBo3+g= X-Google-Smtp-Source: ABdhPJyJRDlO6y7Ut414PuBkSXqf72BoYpRhgqhNF/KxBeXFTgZD8Uf9HGTaJ0n5DqEzA66ZlxQhxwMXC3W+l8W4lWs= X-Received: by 2002:a17:90b:3805:: with SMTP id mq5mr9400092pjb.143.1632591972701; Sat, 25 Sep 2021 10:46:12 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sat, 25 Sep 2021 10:46:12 -0700 From: Stefan Kangas In-Reply-To: =?UTF-8?B?PG0xcG1zd3pzZGEuZnNmQHlhaG9vLmVzPiAoIkRhbmllbCBNYXJ0w61uIidzIG1l?= =?UTF-8?B?c3NhZ2Ugb2YgIlNhdCwgMjUgU2VwIDIwMjEgMTU6Mzk6NDUgKzAyMDAiKQ==?= References: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Date: Sat, 25 Sep 2021 10:46:12 -0700 Message-ID: Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" To: =?UTF-8?Q?Daniel_Mart=C3=ADn?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 50801 Cc: 50801@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.5 (/) Daniel Mart=C3=ADn writes: > I'm reviewing the manuals for the upcoming Emacs 28 and I have a couple > of minor suggestions for node "49.2.4.1 Specifying File Variables": That is extremely useful, thank you very much for working on this. (BTW, you can press `w' in info to get a reference like "(emacs) Specifying File Variables". This is not super important, but a handy feature to know about, as you can then `M-: (info "...")' and get to that section quickly.) > The node doesn't explictly mention the crucial information that in > 'mode: MODENAME' 'MODENAME' must not end in "-mode". It's true that > there's an example down there that says "mode: Lisp", so users may infer > that you don't need to spell the major mode with "-mode", but I thought > it may be better to be explicit about in the manual. Fully agreed. Perhaps something like this? diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index d12033f841..d5f18fff35 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -1084,8 +1084,9 @@ Specifying File Variables @noindent You can specify any number of variable/value pairs in this way, each pair with a colon and semicolon. The special variable/value pair -@code{mode: @var{modename};}, if present, specifies a major mode. The -@var{value}s are used literally, and not evaluated. +@code{mode: @var{modename};}, if present, specifies a major mode +(excluding the ``-mode'' part). The @var{value}s are used literally, +and not evaluated. @findex add-file-local-variable-prop-line @findex delete-file-local-variable-prop-line > Another suggestion I have is that the manual doesn't mention that > something like "-*- C++ -*-" (that is, omitting the "mode" keyword) is > also supported. Many free software projects have traditionally been > using "-* C++ -*" in their C++ header files to make Emacs distinguish > them from plain C files. See also src/epaths.in in the Emacs > repository, among others. I see this used by Jim Blandy since 1992 at > least, but I don't really know if a) it's really a stable way to declare > a file-local mode, and we may lack the historical info to answer that, > and b) it's worth mentioning it in the manual. I can't remember the details, but I believe that this form is considered obsolete and/or problematic. So I think it's fine to not document it. From debbugs-submit-bounces@debbugs.gnu.org Sat Sep 25 14:22:43 2021 Received: (at 50801) by debbugs.gnu.org; 25 Sep 2021 18:22:43 +0000 Received: from localhost ([127.0.0.1]:34690 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUCJv-00009H-1T for submit@debbugs.gnu.org; Sat, 25 Sep 2021 14:22:43 -0400 Received: from sonic312-26.consmr.mail.ir2.yahoo.com ([77.238.178.97]:44549) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUCJr-000092-Hq for 50801@debbugs.gnu.org; Sat, 25 Sep 2021 14:22:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.es; s=s2048; t=1632594153; bh=igJGnaMLiH5C43YdomaZvMhKhL0ElPfKxaF2O7l5Owc=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From:Subject:Reply-To; b=sWsS81UamQfq1XOjR5cE+h4O+lQgQOvWvIn/GzimqBmcwp82ND7heOtJV1i7OaNGsj+M3ZCWnGv6AMPXC+4KxOnwq9OoJGYRs1sNABgO5owsflHX70EziXPB0i9G0r+QfOWIsg89lD50P18TUms9X67nvsqJ9egW7rwPl2IDKL5p7I1f9OMAGYn6mdPJvtdI6Gd37gCVjQxWLj1VJqGNz07a8ePVOWntsvWExQ6VDPNX/OYPmo7yB9Ebp93IhJnRPtZcDgXh339cnBbIQwIQy2kL12xZ8Tebz0xdgoq754033nMQlbbd4FYe1FaDceUAeoANLXH8intPoLGJQn4aDw== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1632594153; bh=HchMVK2NWEZxBW75SiAByJ2E8O8aA2ZkvhvPdZdZd8l=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=DuzJKUQEjezDQTmgnhw2iOuihBratThVOsvrYwaDRF3U7wABTUtI9jVcXppysYrLBwsyhrLkn34rlpwUV8rH8MMEzEepu7H0aD8vh1oC7v6om0EazEbk2FVaFJUOfopB5gNV6ys7l0zZtxFH85g2yTGJwqcC9uovapMw+SjgOxheRwu6dpSCYL/bI3XiAX1uXviJJmstx+2eFfGOilF6B6RtdInb/3Nq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Ooa5hTpwxez4V1A_2R2fciYTa0olWC6YXs6P7fo9ZI1AYBQEP1 kD9ZwZeZaahX.1vfB06eOxaheW7bPFQC.C340hpVrEgH_5YxQsT_P_hLXHGsrY9Z7MGIFfD54O_R Sb0pRu_aY2tAkiQeCHVE_HByEwhPdcBTB5zkRThoORmoIdVP9SpvluS9fsyCS1oExlkDjTRNI.GI VLIg2ipCdGftBiNX.9KMMY4jR4QJ59Pz5Q6BFH1XnfzNMNycBHlOIvqvcjpHqe0dFuzhPF0_N6yf cwIf.mH.ZH43jDlEI4XuNAKNt7U0HbeWHGKim9_ImeCJK5qJTqcRq61z7HDc_vOrT46w- X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic312.consmr.mail.ir2.yahoo.com with HTTP; Sat, 25 Sep 2021 18:22:33 +0000 Received: by kubenode529.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID 0fc5f190f53e3abe3567e293bc2d3608; Sat, 25 Sep 2021 18:22:29 +0000 (UTC) From: =?utf-8?Q?Daniel_Mart=C3=ADn?= To: Stefan Kangas Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" References: Date: Sat, 25 Sep 2021 20:22:28 +0200 In-Reply-To: (Stefan Kangas's message of "Sat, 25 Sep 2021 10:46:12 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-Mailer: WebService/1.1.19043 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo Content-Length: 2648 X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 50801 Cc: 50801@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.8 (/) Stefan Kangas writes: > >> I'm reviewing the manuals for the upcoming Emacs 28 and I have a couple >> of minor suggestions for node "49.2.4.1 Specifying File Variables": > > That is extremely useful, thank you very much for working on this. > > (BTW, you can press `w' in info to get a reference like "(emacs) > Specifying File Variables". This is not super important, but a handy > feature to know about, as you can then `M-: (info "...")' and get to > that section quickly.) Yep, I forgot to add a direct link to the Info node, sorry. BTW you can 'C-u w' to get the link inside a function call to `info` directly. > >> The node doesn't explictly mention the crucial information that in >> 'mode: MODENAME' 'MODENAME' must not end in "-mode". It's true that >> there's an example down there that says "mode: Lisp", so users may infer >> that you don't need to spell the major mode with "-mode", but I thought >> it may be better to be explicit about in the manual. > > Fully agreed. Perhaps something like this? > > diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi > index d12033f841..d5f18fff35 100644 > --- a/doc/emacs/custom.texi > +++ b/doc/emacs/custom.texi > @@ -1084,8 +1084,9 @@ Specifying File Variables > @noindent > You can specify any number of variable/value pairs in this way, each > pair with a colon and semicolon. The special variable/value pair > -@code{mode: @var{modename};}, if present, specifies a major mode. The > -@var{value}s are used literally, and not evaluated. > +@code{mode: @var{modename};}, if present, specifies a major mode > +(excluding the ``-mode'' part). The @var{value}s are used literally, > +and not evaluated. I'm not a native speaker but it reads well to me, thank you. > > @findex add-file-local-variable-prop-line > @findex delete-file-local-variable-prop-line > >> Another suggestion I have is that the manual doesn't mention that >> something like "-*- C++ -*-" (that is, omitting the "mode" keyword) is >> also supported. Many free software projects have traditionally been >> using "-* C++ -*" in their C++ header files to make Emacs distinguish >> them from plain C files. See also src/epaths.in in the Emacs >> repository, among others. I see this used by Jim Blandy since 1992 at >> least, but I don't really know if a) it's really a stable way to declare >> a file-local mode, and we may lack the historical info to answer that, >> and b) it's worth mentioning it in the manual. > > I can't remember the details, but I believe that this form is considered > obsolete and/or problematic. So I think it's fine to not document it. Makes sense. From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 26 02:59:48 2021 Received: (at 50801) by debbugs.gnu.org; 26 Sep 2021 06:59:48 +0000 Received: from localhost ([127.0.0.1]:35609 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUO8a-0003e1-8d for submit@debbugs.gnu.org; Sun, 26 Sep 2021 02:59:48 -0400 Received: from quimby.gnus.org ([95.216.78.240]:47982) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUO8R-0003da-3l for 50801@debbugs.gnu.org; Sun, 26 Sep 2021 02:59:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=jhfxV22IZqmpB/1PNcKKx/ydqaUdIrQCxAy2FvI2R1A=; b=Rcs2Jmf+A0vb+92/qKRTRQoPj7 rusL3pwctPx/chgCMQLWqnLSP4/ut3hbTCshckkvhTfKF1fkfb6Q3xqRQMQyQ42oimGfeFJBURSK7 osbOm2TpyLDWSOqGcVYGa2ubk9gQBHP17jlXNi6rvxLYlId9mYU3L5NDAmZoqKN9ANec=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mUO8I-0006PS-Nf; Sun, 26 Sep 2021 08:59:33 +0200 From: Lars Ingebrigtsen To: Stefan Kangas Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" References: X-Now-Playing: Japan's _Quiet Life (3): Live At The Budokan 1980_: "...Rhodesia" Date: Sun, 26 Sep 2021 08:59:28 +0200 In-Reply-To: (Stefan Kangas's message of "Sat, 25 Sep 2021 10:46:12 -0700") Message-ID: <8735prstyn.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Stefan Kangas writes: > -@code{mode: @var{modename}; }, if present, specifies a major mode. The > -@var{value}s are used literally, and not evaluated. > +@code{mode: @var{modename};}, if present, specifies a major mode > +( [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50801 Cc: 50801@debbugs.gnu.org, Daniel =?utf-8?Q?Mart=C3=ADn?= 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 (---) Stefan Kangas writes: > -@code{mode: @var{modename};}, if present, specifies a major mode. The > -@var{value}s are used literally, and not evaluated. > +@code{mode: @var{modename};}, if present, specifies a major mode > +(excluding the ``-mode'' part). The @var{value}s are used literally, > +and not evaluated. Makes sense to me. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 26 03:09:24 2021 Received: (at 50801) by debbugs.gnu.org; 26 Sep 2021 07:09:24 +0000 Received: from localhost ([127.0.0.1]:35628 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUOHs-000649-6t for submit@debbugs.gnu.org; Sun, 26 Sep 2021 03:09:24 -0400 Received: from mail-out.m-online.net ([212.18.0.9]:45419) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUOHp-00063y-Kc for 50801@debbugs.gnu.org; Sun, 26 Sep 2021 03:09:22 -0400 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 4HHH281Tnnz1qwGd; Sun, 26 Sep 2021 09:09:20 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 4HHH276vfnz1qqkD; Sun, 26 Sep 2021 09:09:19 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id WGNO8BWksFAU; Sun, 26 Sep 2021 09:09:19 +0200 (CEST) X-Auth-Info: oCXhxhn4nNtULDYzkx5qaU6+IW75xIw7clqUhjMLgtHxNdDp4dnAX72ZvGl58lh5 Received: from tiger.home (ppp-46-244-183-128.dynamic.mnet-online.de [46.244.183.128]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Sun, 26 Sep 2021 09:09:19 +0200 (CEST) Received: by tiger.home (Postfix, from userid 1000) id E73EF6304E; Sun, 26 Sep 2021 09:09:17 +0200 (CEST) From: Andreas Schwab To: Stefan Kangas Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" References: X-Yow: Please come home with me... I have Tylenol!! Date: Sun, 26 Sep 2021 09:09:17 +0200 In-Reply-To: (Stefan Kangas's message of "Sat, 25 Sep 2021 10:46:12 -0700") Message-ID: <877df3olsy.fsf@linux-m68k.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.5 (/) X-Debbugs-Envelope-To: 50801 Cc: 50801@debbugs.gnu.org, Daniel =?utf-8?Q?Mart=C3=ADn?= 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.5 (-) On Sep 25 2021, Stefan Kangas wrote: > diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi > index d12033f841..d5f18fff35 100644 > --- a/doc/emacs/custom.texi > +++ b/doc/emacs/custom.texi > @@ -1084,8 +1084,9 @@ Specifying File Variables > @noindent > You can specify any number of variable/value pairs in this way, each > pair with a colon and semicolon. The special variable/value pair > -@code{mode: @var{modename};}, if present, specifies a major mode. The > -@var{value}s are used literally, and not evaluated. > +@code{mode: @var{modename};}, if present, specifies a major mode > +(excluding the ``-mode'' part). The @var{value}s are used literally, without the ``-mode'' suffix Andreas. -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different." From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 26 06:05:42 2021 Received: (at 50801) by debbugs.gnu.org; 26 Sep 2021 10:05:42 +0000 Received: from localhost ([127.0.0.1]:35957 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUR2K-0006ke-UF for submit@debbugs.gnu.org; Sun, 26 Sep 2021 06:05:42 -0400 Received: from mail-pl1-f175.google.com ([209.85.214.175]:44862) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUR2J-0006kM-9q for 50801@debbugs.gnu.org; Sun, 26 Sep 2021 06:05:32 -0400 Received: by mail-pl1-f175.google.com with SMTP id t11so9659678plq.11 for <50801@debbugs.gnu.org>; Sun, 26 Sep 2021 03:05:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=EO+f92Pjq05m8yJQrdW9EQyUDx1OvmLV8/b0v2bqyuM=; b=Jf473T1eJGkvZ+DDc7DS42gWqZDHk1lOIjwBMMGmtuXZUP8IxVpqRsPWepAE2XbcsS agYUjwAJ2sHUBadB8taVzadVYCA42PMKe+dgWOE9viHJ+w0t5Q5EADGgSui47mS0rlEc TR465hsIMVdBGfl7WkQ5D9cserthkN6EAJREEHjNGVFxfh2y8C36hJpSFplj5namBovx 6orVMYREUSOI8r/pGJOd4Iwkqu2hjuRdK/7Iyo8JOzYA2L6/YaSdFLa0L+NF66SFo9l2 N7l3E6rB/QqFC4Qv0kDl1GTNd389eyvjsm2dbxJrQ4NB4UBgz0wxZ/ske3EFqicQ9iN4 XTdA== X-Gm-Message-State: AOAM531g+5xhtmQIHGDOC5na7uxmeiTUEyNwrE0oC/U5m6ahi2f5zX/T 8dYZdTt1+fKzqYsEVj1sfVmF5AzjPVaEt5phpUw= X-Google-Smtp-Source: ABdhPJy9gcKJ679zKIsft29RW8OH5LKNjGUe2pIA+6Y8NsuGzxXRLb58GCr20QcWoKuVwCOzirGl73Kr1GU3NjmeQ9w= X-Received: by 2002:a17:90b:3805:: with SMTP id mq5mr12946280pjb.143.1632650725443; Sun, 26 Sep 2021 03:05:25 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 26 Sep 2021 03:05:25 -0700 From: Stefan Kangas In-Reply-To: <8735prstyn.fsf@gnus.org> References: <8735prstyn.fsf@gnus.org> MIME-Version: 1.0 Date: Sun, 26 Sep 2021 03:05:24 -0700 Message-ID: Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" To: Lars Ingebrigtsen Content-Type: text/plain; charset="UTF-8" X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 50801 Cc: 50801@debbugs.gnu.org, =?UTF-8?Q?Daniel_Mart=C3=ADn?= 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.5 (/) tags 50801 fixed close 50801 28.1 thanks Lars Ingebrigtsen writes: > Stefan Kangas writes: > >> -@code{mode: @var{modename};}, if present, specifies a major mode. The >> -@var{value}s are used literally, and not evaluated. >> +@code{mode: @var{modename};}, if present, specifies a major mode >> +(excluding the ``-mode'' part). The @var{value}s are used literally, >> +and not evaluated. > > Makes sense to me. Thanks, I have now made this change on master (commit 68994995db) with the improvement suggested by Andreas. I'm therefore closing this bug report. From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 27 18:35:02 2021 Received: (at 50801) by debbugs.gnu.org; 27 Sep 2021 22:35:02 +0000 Received: from localhost ([127.0.0.1]:43068 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUzDC-0000Wr-Cx for submit@debbugs.gnu.org; Mon, 27 Sep 2021 18:35:02 -0400 Received: from eggs.gnu.org ([209.51.188.92]:54626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mUzD5-0000W4-3P for 50801@debbugs.gnu.org; Mon, 27 Sep 2021 18:35:01 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:45628) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mUzCz-0002nt-6L; Mon, 27 Sep 2021 18:34:49 -0400 Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1mUzCz-0003qA-2F; Mon, 27 Sep 2021 18:34:49 -0400 Content-Type: text/plain; charset=Utf-8 From: Richard Stallman To: Andreas Schwab In-Reply-To: <877df3olsy.fsf@linux-m68k.org> (message from Andreas Schwab on Sun, 26 Sep 2021 09:09:17 +0200) Subject: Re: bug#50801: 28.0.50; Emacs manual about file variables doesn't mention that major modes shouldn't end in "-mode" References: <877df3olsy.fsf@linux-m68k.org> Message-Id: Date: Mon, 27 Sep 2021 18:34:49 -0400 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 50801 Cc: 50801@debbugs.gnu.org, stefan@marxist.se, mardani29@yahoo.es 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: , Reply-To: rms@gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) [[[ To any NSA and FBI agents reading my email: please consider ]]] [[[ whether defending the US Constitution against all enemies, ]]] [[[ foreign or domestic, requires you to follow Snowden's example. ]]] > > +@code{mode: @var{modename};}, if present, specifies a major mode > > +(excluding the ``-mode'' part). The @var{value}s are used literally, > without the ``-mode'' suffix Indeed. `-mode' is NOT part of the mode's name. The name of Mail mode, which I'm using now, is "Mail", not "Mail mode". -- Dr Richard Stallman (https://stallman.org) Chief GNUisance of the GNU Project (https://gnu.org) Founder, Free Software Foundation (https://fsf.org) Internet Hall-of-Famer (https://internethalloffame.org) From unknown Wed Jun 25 00:21:42 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 26 Oct 2021 11:24:04 +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