From debbugs-submit-bounces@debbugs.gnu.org Mon May 16 10:00:33 2022 Received: (at submit) by debbugs.gnu.org; 16 May 2022 14:00:33 +0000 Received: from localhost ([127.0.0.1]:54660 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nqbGz-0000wc-61 for submit@debbugs.gnu.org; Mon, 16 May 2022 10:00:33 -0400 Received: from lists.gnu.org ([209.51.188.17]:55956) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nqbGx-0000wR-9G for submit@debbugs.gnu.org; Mon, 16 May 2022 10:00:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39018) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nqbGs-0000oh-LY for bug-gnu-emacs@gnu.org; Mon, 16 May 2022 10:00:30 -0400 Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]:39537) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nqbGm-0000Rw-If for bug-gnu-emacs@gnu.org; Mon, 16 May 2022 10:00:25 -0400 Received: by mail-pl1-x62d.google.com with SMTP id bh5so2714926plb.6 for ; Mon, 16 May 2022 07:00:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:date:message-id:mime-version; bh=OcnVZkxhLAJ0khvTT8totRgO2aL95IMd+VrzNX4eKvs=; b=p2G+r4EPVEs17yjMUSQ2rh49VPvV8ylDojYgXmbAObL2w2yk7QfRd/ZVJKJLCx0NsO j7KJbOQhNL8uljVrheq5ppAZWlBAUKy4lVhQ4QVJnguAI4SysOxf6lUVb3iC8OLhbz5r dhwfe+EgaSOVvUt8hiPs/FV/VxXpgPZCodG6x0JrXqOnn6ql1X1Pr3o47YBM8O43ROyX Tc8L2oJC9hYACRafzr6xUOonIBhjOEal98pycNALml7OvN+uKBWMWqH5uxMEN+GS5Upp roCi2BHbRsLrRKfKvbsKYGxZCwSy+JNG8hMS5b9IUW0pS3DsJdJ+wEi4Ew3k+HVOZkju tZ1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=OcnVZkxhLAJ0khvTT8totRgO2aL95IMd+VrzNX4eKvs=; b=NhDRRFPgFMDrIA9I9QouPw9l1GXkxPuntTI30+svNzQD3z2Npq4rcCD3YK7dFIZp3g dM4THLthRjLylsI1L2wFbTm8LcfA1bt11ZjYcSI82Mcm+WF0z2tAqkLIwjPUV9eftFbn t4a6vyTvMvBRgU/SMuIQGMz7vxWX/G+hPtSpunEc4nVdRsMxZVafkm/cgcDdu4zLOjcC IJWBVc+qpSvmUCgtNxaO4ilI2TP3fK/g4zXi0Rz6P3jzK3Xcjd/491fhxPbTCpRBt7mO ngNMEPcL0fHo0b8XMgBysQJ9RD99SbZuL5XNgJjIS2D3Wqki5ZXQtIKfsFTjEy1FRng5 RgGQ== X-Gm-Message-State: AOAM532KWkol4noMPEt6benhDqhngt99A1rcWr75G+bLmCvWZW9cn1Al EVNNkjC1Xu4iUTnHfkMxJYW2fB4Twwv+TQ== X-Google-Smtp-Source: ABdhPJzvE62jWL5A3rshCDm7hNCZl79XopJEue15rMaV3qx0LirwYXx90gDyGiQyDjDb8hcb/dwFqg== X-Received: by 2002:a17:903:2055:b0:161:7399:3b89 with SMTP id q21-20020a170903205500b0016173993b89mr6271446pla.22.1652709617680; Mon, 16 May 2022 07:00:17 -0700 (PDT) Received: from localhost ([38.75.137.213]) by smtp.gmail.com with ESMTPSA id r23-20020a17090aa09700b001d77f392280sm6546671pjp.30.2022.05.16.07.00.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 May 2022 07:00:17 -0700 (PDT) From: Ihor Radchenko To: bug-gnu-emacs@gnu.org Subject: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode Date: Mon, 16 May 2022 22:00:58 +0800 Message-ID: <871qwtshk5.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::62d; envelope-from=yantar92@gmail.com; helo=mail-pl1-x62d.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 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_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.1 (-) 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.1 (--) Hi, I recently tried to disable jit-lock-mode using the usual syntax (jit-lock-mode -1) However, the mode was not disabled, which is unexpected. I believe that the problem is caused by .... If you need to debug code run from jit-lock, see `jit-lock-debug-mode'." (setq jit-lock-mode arg) ;; <- this sets jit-lock-mode to non-nil even if I pass -1 argument (cond ((and (buffer-base-buffer) .... Best, Ihor From debbugs-submit-bounces@debbugs.gnu.org Mon May 16 11:53:25 2022 Received: (at 55451) by debbugs.gnu.org; 16 May 2022 15:53:25 +0000 Received: from localhost ([127.0.0.1]:54837 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nqd2D-0003xs-0T for submit@debbugs.gnu.org; Mon, 16 May 2022 11:53:25 -0400 Received: from eggs.gnu.org ([209.51.188.92]:46008) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nqd2B-0003xf-Br for 55451@debbugs.gnu.org; Mon, 16 May 2022 11:53:23 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:38862) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nqd25-0002f4-QB; Mon, 16 May 2022 11:53:18 -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=cfJsY1M+yBExrlthEyRt2CytxWLyemIctLjK6Cwva2g=; b=ZC3wEg86nDn3 dyBBPGm00yO081tLJ60YkTw18PzzDlfh7DBK+39KndRWqRzVlUatGe1IJdJl/FUv/6LQ7GUtBR/9a 7HcIhLaX1xnlTFxnI/5bIn0qkL+XK4MEeT9ci4iiqWiHwf5Rxpwq0LVZnBn7qBW+3GW5QUZLKDMb7 ZDiJhaWrbocHzZkI+sVoOZ0wJBQOx8xeUS31yQHvW8VXrbOZ19qG3herrCunWmXtzhXEkn2+lH+a8 GIrqYmlVAeeNXBkPDzecdG8g7QYzIjIET0Nz+wyM5XaRloogMiiQoKQGmBpGl28AmvvdtDdvWuxU+ Ba/nIZERghxQ7JaysaF+8Q==; Received: from [87.69.77.57] (port=2264 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 1nqd25-0008BF-1f; Mon, 16 May 2022 11:53:17 -0400 Date: Mon, 16 May 2022 18:53:06 +0300 Message-Id: <83sfp9iie5.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <871qwtshk5.fsf@localhost> (message from Ihor Radchenko on Mon, 16 May 2022 22:00:58 +0800) Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55451 Cc: 55451@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: Ihor Radchenko > Date: Mon, 16 May 2022 22:00:58 +0800 > > I recently tried to disable jit-lock-mode using the usual syntax > (jit-lock-mode -1) jit-lock-mode is not a minor mode, so the usual syntax doesn't work with it, and isn't documented to work. Set it to nil to disable. From debbugs-submit-bounces@debbugs.gnu.org Tue May 17 14:03:55 2022 Received: (at 55451) by debbugs.gnu.org; 17 May 2022 18:03:55 +0000 Received: from localhost ([127.0.0.1]:57891 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nr1Y3-000052-DB for submit@debbugs.gnu.org; Tue, 17 May 2022 14:03:55 -0400 Received: from quimby.gnus.org ([95.216.78.240]:56284) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nr1Y1-0008WT-U0 for 55451@debbugs.gnu.org; Tue, 17 May 2022 14:03:54 -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=Ng0uH5yVwUHatlcYvNO65i4XVU42LAB5Asv9vanHWyE=; b=Xn+RceekwXytcDwZLfo2CdM3DZ ZM8TIeAxQRaBrZXiMY4IP3LNCasSDQMFUmyTfLbEmKDmYrL3hwRBiDFcl8rUKjXfA6yu3z1L/6KYG c/PoVZQSQA0r5d4V8gJVok/eT6DkUEXXqetLDmQukVp/efQW7eInt1TvOJrnkl2ZrMq4=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nr1Xt-0004rm-1y; Tue, 17 May 2022 20:03:47 +0200 From: Lars Ingebrigtsen To: Eli Zaretskii Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> X-Now-Playing: Dry Cleaning's _Sweet Princess EP_: "Phone Scam" Date: Tue, 17 May 2022 20:03:44 +0200 In-Reply-To: <83sfp9iie5.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 16 May 2022 18:53:06 +0300") Message-ID: <87bkvwjatb.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.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: Eli Zaretskii writes: > jit-lock-mode is not a minor mode, so the usual syntax doesn't work > with it, and isn't documented to work. Set it to nil to disable. The doc string could do with some explicit text about this, so I've added that to Emacs 29. But since this is working as intended, I'm closing this bug report. 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: 55451 Cc: Ihor Radchenko , 55451@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 (---) Eli Zaretskii writes: > jit-lock-mode is not a minor mode, so the usual syntax doesn't work > with it, and isn't documented to work. Set it to nil to disable. The doc string could do with some explicit text about this, so I've added that to Emacs 29. But since this is working as intended, I'm closing this bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Tue May 17 14:04:00 2022 Received: (at control) by debbugs.gnu.org; 17 May 2022 18:04:01 +0000 Received: from localhost ([127.0.0.1]:57894 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nr1Y8-00005P-Jm for submit@debbugs.gnu.org; Tue, 17 May 2022 14:04:00 -0400 Received: from quimby.gnus.org ([95.216.78.240]:56300) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nr1Y6-00004v-Hr for control@debbugs.gnu.org; Tue, 17 May 2022 14:03:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=MpzXlcMZu/RBuVfLgRKLj94s21r2Ud/bT8mDuqX93mk=; b=mzFohZVpF6xDNpsbdh0FaUNUuw 1PGqnSBH9FKtLvO3EhmXc2hz5TFal70E3lSny7bYf/539/1UF+wBO/ObKEJujMNOtwE4PmqWj4Aeo 8HfGPxovihiUr/JLkz81syXADbkC6B4mtdwsMTiM0iPLPRp9rKFVYLnFaXn5DNQy8eUY=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nr1Xz-0004ry-22 for control@debbugs.gnu.org; Tue, 17 May 2022 20:03:52 +0200 Date: Tue, 17 May 2022 20:03:50 +0200 Message-Id: <87a6bgjat5.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #55451 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: close 55451 29.1 quit 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: control 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 (---) close 55451 29.1 quit From debbugs-submit-bounces@debbugs.gnu.org Wed May 18 07:46:03 2022 Received: (at 55451) by debbugs.gnu.org; 18 May 2022 11:46:03 +0000 Received: from localhost ([127.0.0.1]:59196 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrI7u-0006Jt-OY for submit@debbugs.gnu.org; Wed, 18 May 2022 07:46:03 -0400 Received: from mail-pj1-f43.google.com ([209.85.216.43]:52985) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrI7s-0006Bz-Rx for 55451@debbugs.gnu.org; Wed, 18 May 2022 07:46:01 -0400 Received: by mail-pj1-f43.google.com with SMTP id l14so1766595pjk.2 for <55451@debbugs.gnu.org>; Wed, 18 May 2022 04:46:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=quKAUlnoDpO/lEtZ4G5/lzGMEtCJk1dlBttiavZxXxU=; b=XpJgKyQHDG+/8XHEBW2TuggFZWfVWqcpJ3koEanAwYMDuCqpeUANbefDWMShf5NDPR K0A4RdvAkT7MDIc1RDfIJaQMT/pLbsuUZcM853+kHjSh/dW7o/vDfTMvotzgksBMilj8 b+xRFqSUWyLB2GNKGq0LbvqrKYaeIDT6C2V0gTRfjLcXos8f0cjgd6Kvu1QqSerGtxlp xXhsUaa9vtf3zohFS+LP9rU+UMPLO8USmiibL2KgX2BwC5UgxzACcifGk0TqESuQ7MPh 385sYaFDBJlBTINTBdRvWNDuvOJBwdbwXzE/kZJ9r3IK89MgXzEmX3pT+xQpTiT9DqPz JOMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=quKAUlnoDpO/lEtZ4G5/lzGMEtCJk1dlBttiavZxXxU=; b=w2KZoqPX234Wkk3bAWyfOi9FPRloKE+y/ULH7Ed+WfOqZQ2dz6ihnnXpHdoZcrTnzY IMeMt5aYY5Zw9zTS3MPvZAmJLlArB8MNVBUbzG89CXq2aoSTwOk6URaDIz+uEuIvOVRJ r0vPZjZRgDVeKZq586QD+gpKFFyCSf0JSGCo551Oq9XF16fST+oPLjqc8Y5mIIX3wdHi d0RbkEem4VRvY/IXeW8jQGBhcTDhyHmzu3e9Ej7QlnT3R7rFqQ1kz5LA/1YPEAl0rsLu NL+f7+/bQU3Hj+ojo54kOmVGcN3yV6fYVYsr84aeY8UznrfF+jVvStxQB1my81hMsEt+ SCDA== X-Gm-Message-State: AOAM533ogE4OFbOWNVg1MTv16hJI/UVNSfsCRgLyrvI+PhK0HiLe0E8w X/mzyuIt21MB2nM9JhlywHVLeGpmdyg= X-Google-Smtp-Source: ABdhPJy/6ILYGCozHwmi/Dsy+dt0ma1u6izatuiGvJg0Qe4lQkXiuANXi6Sfl7J1j/f2f0yIFjcULg== X-Received: by 2002:a17:903:120a:b0:15f:99f:95bc with SMTP id l10-20020a170903120a00b0015f099f95bcmr26817878plh.48.1652874354860; Wed, 18 May 2022 04:45:54 -0700 (PDT) Received: from localhost ([134.73.242.163]) by smtp.gmail.com with ESMTPSA id e14-20020a17090301ce00b0016194c1df58sm1524063plh.105.2022.05.18.04.45.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 May 2022 04:45:54 -0700 (PDT) From: Ihor Radchenko To: Lars Ingebrigtsen Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode In-Reply-To: <87bkvwjatb.fsf@gnus.org> References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> Date: Wed, 18 May 2022 19:46:35 +0800 Message-ID: <871qwr2hd0.fsf@localhost> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 55451 Cc: Eli Zaretskii , 55451@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 (/) --=-=-= Content-Type: text/plain Lars Ingebrigtsen writes: > Eli Zaretskii writes: > >> jit-lock-mode is not a minor mode, so the usual syntax doesn't work >> with it, and isn't documented to work. Set it to nil to disable. > > The doc string could do with some explicit text about this, so I've > added that to Emacs 29. But since this is working as intended, I'm > closing this bug report. Thanks! It certainly improves the situation. However, I am confused why it is impossible to follow +1/-1 convention. Looking through jit-lock.el I do not see any place where any value other than non-nil/nil is considered. A possible patch is attached. Best, Ihor --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-jit-lock-mode-Treat-1-and-1-ARG-as-other-normal-mino.patch >From a9da60ba42f6745f4bbdb305e057639c40f8d34e Mon Sep 17 00:00:00 2001 Message-Id: From: Ihor Radchenko Date: Wed, 18 May 2022 19:44:25 +0800 Subject: [PATCH] jit-lock-mode: Treat +1 and -1 ARG as other normal minor modes * lisp/jit-lock.el (jit-lock-mode): Recognise +1/-1 arguments using minor mode conventions. --- lisp/jit-lock.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/jit-lock.el b/lisp/jit-lock.el index 20c1202474..224223fc7e 100644 --- a/lisp/jit-lock.el +++ b/lisp/jit-lock.el @@ -218,7 +218,12 @@ jit-lock-mode the variable `jit-lock-stealth-nice'. If you need to debug code run from jit-lock, see `jit-lock-debug-mode'." - (setq jit-lock-mode arg) + (setq jit-lock-mode + (pcase arg + (`+1 t) + (`-1 nil) + (`nil nil) + (val val))) (cond ((and (buffer-base-buffer) jit-lock-mode) -- 2.35.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 18 13:28:13 2022 Received: (at 55451) by debbugs.gnu.org; 18 May 2022 17:28:13 +0000 Received: from localhost ([127.0.0.1]:33415 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrNT3-00058f-25 for submit@debbugs.gnu.org; Wed, 18 May 2022 13:28:13 -0400 Received: from quimby.gnus.org ([95.216.78.240]:42184) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrNT0-00058R-UI for 55451@debbugs.gnu.org; Wed, 18 May 2022 13:28:11 -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=FOVtnY59zgs2ZPMFlvGnUsy62f7zRsLVpVhWg/IgzBw=; b=gKMcl6ZfdDhKSsxUmPhM8xnd3p 5pS8P0Kt//iPyirdINnUmk+qMppGHfg/MilG+gxmsN6uBKjePcF7w7d8yTn7lwUcelT51kyQzhFJP /iTpqqzNzy/f5Bx8OWtiTPdjQNAeukZG3NRCv5+YzC/Pbr7xMY+5weA7QvKJhKarUAaQ=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nrNSr-0001Bt-EA; Wed, 18 May 2022 19:28:03 +0200 From: Lars Ingebrigtsen To: Ihor Radchenko Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAG1BMVEXLEF4MHW01S6pc k+EGDVUIBhsvSkSldZ////8Uojl5AAAAAWJLR0QIht6VegAAAAd0SU1FB+YFEhEaKkhLuBEAAAF7 SURBVDjLddO9csIwDADgpHB0Fhj2yBydi5/AVH4BLmbuQDNz7V15/Ur+iR1KtCVfZCmR0jQlWpBY o4Su7jd8LaDNEbWpYQ3YScaRn6ihVRSPegRyPfX2PyzJeS+gp7Ai8gxkUUvtAtcCBk0BTnABiNs1 FVxnICV4IrITWIYKT0AVoBpamgFI0AtsCvBXquBUAGZgJSe5J9DmEo/AJ3lfwGZ4AeUmoBO0oHwF ljIAOJ+qhwT6GIFCuAixOja3F+jiNSVwZ94fbO7fiJRTop854y2AohwWYPe1CDUEOCUVAsTh82cE vZdHMzQmrI+Aec8pFnbDAvGA95iBe74ZKsF64JaGIQLyMufyJx3gNwF2uWf+CQ4DRwKNBvk9rSIz BdnWo3SgNjV0Gbhpy99jBAhgJAPUCUfoBHQ8CmDbrwPcXlF+VM7YRwjTZGiaTuAoTQUIo7xk6OIH HsFfwszzpAS2NagC417kfcvgalDV/HwN1WDVHGxrWKYdmZTwf16x4jfHCPvVAAAAJXRFWHRkYXRl OmNyZWF0ZQAyMDIyLTA1LTE4VDE3OjI2OjQyKzAwOjAwTihHvwAAACV0RVh0ZGF0ZTptb2RpZnkA MjAyMi0wNS0xOFQxNzoyNjo0MiswMDowMD91/wMAAAAASUVORK5CYII= X-Now-Playing: Juana Molina's _ANRMAL_: "Un =?utf-8?Q?d=C3=ADa=22?= Date: Wed, 18 May 2022 19:27:58 +0200 In-Reply-To: <871qwr2hd0.fsf@localhost> (Ihor Radchenko's message of "Wed, 18 May 2022 19:46:35 +0800") Message-ID: <87zgjeagyp.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.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: Ihor Radchenko writes: > However, I am confused why it is impossible to follow +1/-1 convention. > Looking through jit-lock.el I do not see any place where any value other > than non-nil/nil is considered. 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: 55451 Cc: Eli Zaretskii , 55451@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 (---) Ihor Radchenko writes: > However, I am confused why it is impossible to follow +1/-1 convention. > Looking through jit-lock.el I do not see any place where any value other > than non-nil/nil is considered. It would be incompatible -- all non-nil values switch jit-lock on presently, including -1. It's pretty unlikely that anybody's using -1 to switch it on, though. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Wed May 18 13:41:20 2022 Received: (at 55451) by debbugs.gnu.org; 18 May 2022 17:41:20 +0000 Received: from localhost ([127.0.0.1]:33441 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrNfj-0005Td-Pc for submit@debbugs.gnu.org; Wed, 18 May 2022 13:41:19 -0400 Received: from eggs.gnu.org ([209.51.188.92]:45752) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrNfi-0005TP-RS for 55451@debbugs.gnu.org; Wed, 18 May 2022 13:41:19 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:35900) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nrNfb-0000Vx-0u; Wed, 18 May 2022 13:41:13 -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=7oUlrqvse7/593+mvJevpIXpVfeE+3aJGcn7KjB6Ndw=; b=Tejp0DcJUlSw jl7r6tdSZbDLe/Cr0FREfTxG5agTTM02kiZOVJGNcD03Zc+69TZ3byzfN0JBYPKOFK0gSrYa2LOvl zq12n5XnhiI+I6j+zE6JoX6Rd4S7d5OsYhkgehI0Sexr+cO16NAiQHhzd2kRSbisAFqodywgDuZkW 8RzcwaWMI3vDs2v5Z+r5Z/iqx38uPAnirLYAlwP1OJnt2k9Hbwvgei+EDBcRUxC+SzlXFtex655Dn 0bCt0+hfI5LNmwiZ+kVwrXujVvt0T1ZotvLu1gtPWOpoXX+FvrFD02SRipapbMslVsKCE8VYKOR3P XYslLLOKHRXWoWmKFrRdRA==; Received: from [87.69.77.57] (port=2361 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 1nrNfa-0001Sm-GT; Wed, 18 May 2022 13:41:10 -0400 Date: Wed, 18 May 2022 20:41:05 +0300 Message-Id: <83ilq2eo26.fsf@gnu.org> From: Eli Zaretskii To: Lars Ingebrigtsen In-Reply-To: <87zgjeagyp.fsf@gnus.org> (message from Lars Ingebrigtsen on Wed, 18 May 2022 19:27:58 +0200) Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55451 Cc: yantar92@gmail.com, 55451@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: Lars Ingebrigtsen > Cc: Eli Zaretskii , 55451@debbugs.gnu.org > Date: Wed, 18 May 2022 19:27:58 +0200 > > Ihor Radchenko writes: > > > However, I am confused why it is impossible to follow +1/-1 convention. > > Looking through jit-lock.el I do not see any place where any value other > > than non-nil/nil is considered. > > It would be incompatible -- all non-nil values switch jit-lock on > presently, including -1. Yes. Moreover, it's hardly worth the hassle: who would switch off jit-lock, except for debugging jit-lock? Most people will never do, which is very unlike every minor mode out there -- those are switched on and off all the time. It isn't an accident that we don't have the "M-x jit-lock-mode" command. From debbugs-submit-bounces@debbugs.gnu.org Thu May 19 09:48:49 2022 Received: (at 55451) by debbugs.gnu.org; 19 May 2022 13:48:49 +0000 Received: from localhost ([127.0.0.1]:34841 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrgWH-0001Ve-2I for submit@debbugs.gnu.org; Thu, 19 May 2022 09:48:49 -0400 Received: from mail-pf1-f169.google.com ([209.85.210.169]:47028) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrgWG-0001VS-9e for 55451@debbugs.gnu.org; Thu, 19 May 2022 09:48:48 -0400 Received: by mail-pf1-f169.google.com with SMTP id j6so5190620pfe.13 for <55451@debbugs.gnu.org>; Thu, 19 May 2022 06:48:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=I0xEJwDD07Q4xUbfCwu0YVOrX9FsfDVqwGQoY8VGnw8=; b=VLccqpsPrtpwGMp2l1SlzS7bhFHvhK+DWsJTOU8N/skMbWAKQWDBa6kqoRcFpGCt1f Vqu1aUwan5b3nn5A7NpiL9jS6AN2fm+uXUtBMhEyDBJnXaCCgkv65MzOBMet4F0fObDq 0flINn/F5AGwquUmxA32sZrPUkUNaoUKAaVnmHi4PI6Yn/yNkGBGZOXDDTv1FJHXTBRP hZlzIF3XUzCI8iVoXIrMFPd0vfdp8UU1eqlxIcJhNcIz7vlDQsy2oX/huZcR4Jvcb79d Ciuwdzu0kDmsHQSU6NdsJ9kLphCmq9kWbQaAE69Rg2aDX5Mg8gKxtEMkZUrj2X44LaPi ZwoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=I0xEJwDD07Q4xUbfCwu0YVOrX9FsfDVqwGQoY8VGnw8=; b=o437fQp8QTjmTbCqWIirQR7VtPFqB0Ugv9JXaGKdVK3q1F5749/GmGGPwUa7lXcOqS AFTdkXdbP10EerOqsR5pjFHIjOwi3gSOErr3FQ8ns6MKnzBquk4QYaY3HjQjzDPzzbXw q8ztNrfOQQ0nbfrDA4cuHn5NF7l7glwUhfgcC/OhIyBtoQg7DPubURHNSjmgGH0o7uNA TRAlp/UiGE74G0KnV9R+T1Nx2EgzekhTx5KZ6zvRoxVQJ5s3hPPFugC2e6stR3Rcksqm wPDsH5BEZCPiawVl9U0eyr6i6bFseXriUD99qYfUrSNSnXspmU/HlQF5fw6q//lESJwm BPDg== X-Gm-Message-State: AOAM532JGVjLHc+oFNriFYZlgBp/iHnFR3+mtg2j/UyusF8hF+ALqj0Y he++TrZhqJwwIJavMP4QjiE= X-Google-Smtp-Source: ABdhPJwN/BhxhZxXyJI5acfTahTVUltEntzjRK6lZcqncqMPvR4PSXkJfbB2LZbaUhNXAI0usImlaA== X-Received: by 2002:a63:f003:0:b0:3db:84d3:743d with SMTP id k3-20020a63f003000000b003db84d3743dmr4108725pgh.97.1652968122297; Thu, 19 May 2022 06:48:42 -0700 (PDT) Received: from localhost ([104.223.87.12]) by smtp.gmail.com with ESMTPSA id ep1-20020a17090ae64100b001d96bc27a57sm3511656pjb.54.2022.05.19.06.48.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 May 2022 06:48:41 -0700 (PDT) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode In-Reply-To: <83ilq2eo26.fsf@gnu.org> References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> <83ilq2eo26.fsf@gnu.org> Date: Thu, 19 May 2022 21:49:21 +0800 Message-ID: <87czg94opq.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 55451 Cc: Lars Ingebrigtsen , 55451@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 (/) Eli Zaretskii writes: >> From: Lars Ingebrigtsen >> Cc: Eli Zaretskii , 55451@debbugs.gnu.org >> Date: Wed, 18 May 2022 19:27:58 +0200 >> >> Ihor Radchenko writes: >> >> > However, I am confused why it is impossible to follow +1/-1 convention. >> > Looking through jit-lock.el I do not see any place where any value other >> > than non-nil/nil is considered. >> >> It would be incompatible -- all non-nil values switch jit-lock on >> presently, including -1. > > Yes. Moreover, it's hardly worth the hassle: who would switch off > jit-lock, except for debugging jit-lock? Most people will never do, > which is very unlike every minor mode out there -- those are switched > on and off all the time. It isn't an accident that we don't have the > "M-x jit-lock-mode" command. That's exactly the situation I had: 1. Tried M-x jit-lock-mode. Did not work. Understandable - special minor mode. 2. M-: (jit-lock-mode -1). No error. Executed. 3. Tried to debug something assuming that jit-lock is disabled. 4. After several minutes, realised that jit-lock is still working. So, similar to other Elisp conventions, I do expect everything called minor mode to follow the calling convention with +1/-1. Not doing so is a surprise. Not doing so without a clear indication (like an error) is a recipe for confusion. I would not expect users to read minor mode docstring every time to check if the usual convention is broken. There should be some kind of indication at least, be it an unusual symbol name, a user error, or something similarly noticeable. Best, Ihor From debbugs-submit-bounces@debbugs.gnu.org Thu May 19 10:00:48 2022 Received: (at 55451) by debbugs.gnu.org; 19 May 2022 14:00:48 +0000 Received: from localhost ([127.0.0.1]:36319 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrghr-0002DW-SY for submit@debbugs.gnu.org; Thu, 19 May 2022 10:00:48 -0400 Received: from eggs.gnu.org ([209.51.188.92]:48102) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrghq-0002DK-9U for 55451@debbugs.gnu.org; Thu, 19 May 2022 10:00:46 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:57098) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nrghk-000226-Sm; Thu, 19 May 2022 10:00:40 -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=PwD5Z7lKJJsW8QQf/US/gvzZsGXfBhGwKSXCuYRunRw=; b=YlnDFASBY6w0 IoP7NB99vCf7+546Y+Ukra277QpSpqZlOKT3WRKEdsTXKcdTLtxx2KFE9n0QTehU3C+j0iQZiiZ7Y /D7W+E7TwSfN9Bt7sJGGEqlIZ20f5nvtaoKJ8B7URgyDxukdWHbr5Aqhe8H5c5JFCClnF9sivrf5t 7gibtDQmNBEIfQHmTvjDrgiL+ikP7Ultsa/MWlBjcnw8jsNHD+fHgnwJkQlutIb/RegFgS/wb+g65 4XkQsVoEZ4ipBg31NyyjuJN/DMvy1dqr37sZzKY9vGvKd4m9H+KjP2MNRpDcFd4EJ1kC+iPPMJt9I ab0ORfLMKrbkDH3LObdmTQ==; Received: from [87.69.77.57] (port=1472 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 1nrghj-0000k3-Bn; Thu, 19 May 2022 10:00:40 -0400 Date: Thu, 19 May 2022 17:00:36 +0300 Message-Id: <83mtfdd3ln.fsf@gnu.org> From: Eli Zaretskii To: Ihor Radchenko In-Reply-To: <87czg94opq.fsf@localhost> (message from Ihor Radchenko on Thu, 19 May 2022 21:49:21 +0800) Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> <83ilq2eo26.fsf@gnu.org> <87czg94opq.fsf@localhost> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55451 Cc: larsi@gnus.org, 55451@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: Ihor Radchenko > Cc: Lars Ingebrigtsen , 55451@debbugs.gnu.org > Date: Thu, 19 May 2022 21:49:21 +0800 > > > Yes. Moreover, it's hardly worth the hassle: who would switch off > > jit-lock, except for debugging jit-lock? Most people will never do, > > which is very unlike every minor mode out there -- those are switched > > on and off all the time. It isn't an accident that we don't have the > > "M-x jit-lock-mode" command. > > That's exactly the situation I had: > 1. Tried M-x jit-lock-mode. Did not work. Understandable - special minor > mode. > 2. M-: (jit-lock-mode -1). No error. Executed. > 3. Tried to debug something assuming that jit-lock is disabled. > 4. After several minutes, realised that jit-lock is still working. But the doc string already caters to your use case: If you need to debug code run from jit-lock, see `jit-lock-debug-mode' > I would not expect users to read minor mode docstring every time to > check if the usual convention is broken. Users don't need to turn off jit-lock. People who want to debug it, OTOH, _are_ expected to read the doc string. From debbugs-submit-bounces@debbugs.gnu.org Thu May 19 19:13:51 2022 Received: (at 55451) by debbugs.gnu.org; 19 May 2022 23:13:51 +0000 Received: from localhost ([127.0.0.1]:36834 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrpL5-0004H7-Cx for submit@debbugs.gnu.org; Thu, 19 May 2022 19:13:51 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34758) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrpL3-0004Gu-A8 for 55451@debbugs.gnu.org; Thu, 19 May 2022 19:13:49 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:42746) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nrpKy-0005HB-3L; Thu, 19 May 2022 19:13:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=Date:References:Subject:In-Reply-To:To:From: mime-version; bh=koRhMW7KKCYYJCGIu/b7LcbgcHCpw4J4G0QkvqHaMNk=; b=kKKRxyWyQL2i GtX87fJWpFvW0Ec3xOtnV0nm9sBOpHYnzwCL21NzvTiQkc/6SRwQCsn2uPgmTQBe2gJ5RRgXyKcF6 +LdpKO2Xi7r3Jyq8d8ZfUT0pn9Di5XLd2lDfMFaxDmMh3QVqS1sxTzeaDXhfS+s7UfA2x9Bj/AynG ujGERkrg1irTMinn2yXltuUW7346J+M76yw8nLD8paqIDy5VmSFSwj0PBS9VRWPgWvoomQ1eMJ2Ve Aj8x4c3lxMUSFfCHxJjaCWD3gTuBd0p8zIfkI5e6pSIzWq46ca1pT/D3rYIEGUkC1eI3VGVfwoXQW 1cuuR8Nr3+k+EOzkpRoJbA==; Received: from rms by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1nrpKx-00056q-An; Thu, 19 May 2022 19:13:43 -0400 Content-Type: text/plain; charset=Utf-8 From: Richard Stallman To: Eli Zaretskii In-Reply-To: <83ilq2eo26.fsf@gnu.org> (message from Eli Zaretskii on Wed, 18 May 2022 20:41:05 +0300) Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> <83ilq2eo26.fsf@gnu.org> Message-Id: Date: Thu, 19 May 2022 19:13:43 -0400 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55451 Cc: larsi@gnus.org, yantar92@gmail.com, 55451@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: , 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. ]]] > Yes. Moreover, it's hardly worth the hassle: who would switch off > jit-lock, except for debugging jit-lock? Most people will never do, > which is very unlike every minor mode out there -- those are switched > on and off all the time. It isn't an accident that we don't have the > "M-x jit-lock-mode" command. I don't think I have ever turned off Jit-Lock mode _as such_, but I turn off Font-Lock mode in some major modes. I don't know whether that is that pertinent to this issue; I mention it just in case. -- 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 debbugs-submit-bounces@debbugs.gnu.org Fri May 20 02:55:41 2022 Received: (at 55451) by debbugs.gnu.org; 20 May 2022 06:55:41 +0000 Received: from localhost ([127.0.0.1]:37362 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrwY1-00077I-Ab for submit@debbugs.gnu.org; Fri, 20 May 2022 02:55:41 -0400 Received: from eggs.gnu.org ([209.51.188.92]:33052) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrwXz-00076o-CT for 55451@debbugs.gnu.org; Fri, 20 May 2022 02:55:40 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:49488) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nrwXu-0000Su-1u; Fri, 20 May 2022 02:55:34 -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=NzmcCACL5KTBNNczuJo4lrm4e75EAM7TfQUYb82bz9k=; b=YFUwsNAFIHZG B+D4iTJ6Zwb4GN/1lWpEy6JRKHOtiXdVk0mzG2w+vwcK9QKXSlfnBt+zckqYnWon/pKQ5lLHd6mxg l/VTpsNULFZ9BE2+a4TOYOi3WWBZC1NlD/C7aHeogtiRikXJwQmgPDrZR9RmJXTnewP714ZGKQJkV YFTICqEigxoOQ4gMAg1bNcRZQ4Alyyv4N+NKRnYMBgFZ6VsnjFcD5wgShKO7k05uOTs+jcvSTXb0G PHM4eQbGXin6TT6hotAQq07jKpotpop90nipXqpErCA/Nka+eyn5OGrqF9xQWZtaerWtgb7RSYxYW sklr91HtRPZbRjANMbpV6Q==; Received: from [87.69.77.57] (port=4008 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 1nrwXs-0004je-Ki; Fri, 20 May 2022 02:55:33 -0400 Date: Fri, 20 May 2022 09:55:31 +0300 Message-Id: <83y1ywbsm4.fsf@gnu.org> From: Eli Zaretskii To: rms@gnu.org In-Reply-To: (message from Richard Stallman on Thu, 19 May 2022 19:13:43 -0400) Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> <83ilq2eo26.fsf@gnu.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55451 Cc: larsi@gnus.org, yantar92@gmail.com, 55451@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: Richard Stallman > Cc: larsi@gnus.org, yantar92@gmail.com, 55451@debbugs.gnu.org > Date: Thu, 19 May 2022 19:13:43 -0400 > > > Yes. Moreover, it's hardly worth the hassle: who would switch off > > jit-lock, except for debugging jit-lock? Most people will never do, > > which is very unlike every minor mode out there -- those are switched > > on and off all the time. It isn't an accident that we don't have the > > "M-x jit-lock-mode" command. > > I don't think I have ever turned off Jit-Lock mode _as such_, but I > turn off Font-Lock mode in some major modes. I don't know whether > that is that pertinent to this issue It isn't, AFAIU. From debbugs-submit-bounces@debbugs.gnu.org Fri May 20 04:13:23 2022 Received: (at 55451) by debbugs.gnu.org; 20 May 2022 08:13:23 +0000 Received: from localhost ([127.0.0.1]:37470 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrxlC-00036o-O6 for submit@debbugs.gnu.org; Fri, 20 May 2022 04:13:23 -0400 Received: from mail-pf1-f174.google.com ([209.85.210.174]:46996) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nrxlB-00036S-0n for 55451@debbugs.gnu.org; Fri, 20 May 2022 04:13:21 -0400 Received: by mail-pf1-f174.google.com with SMTP id j6so7131432pfe.13 for <55451@debbugs.gnu.org>; Fri, 20 May 2022 01:13:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=vXwK7/fbEyLO+eLRzjWG5aXgZry85fBpdvl7HHA8mIE=; b=a48kGJHKY2ejTKY6CZ87P1JSYDZuojO43znZFlRD2BLjbQ0Du6clQPyJqolNMtMiKj SDRWSnkyNTAltunsOJVxaLsWx6s2S4AtN2FW9/7IbJLOl/mTKWxCpjXkuvfrYStej5MG 6o/GqN8fM3WGyFJ0lcNxSmhkl9RIbMqVNEoy2QTmE9JdvYaVfQqh8W3fC9I79lokmcak MUdRHtWONRA3mAPpuW+YBj6MUoEcCwWz938nW97tAYyFXC4t9f4XDbQ6+CvGbNSHxVP0 yvKWN8cCG/8SAMOb4aExYTvHfUVzVlsQg39RckpphOjyPtRY/TREGLKtm+wQhxwLXHOC F8Bw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=vXwK7/fbEyLO+eLRzjWG5aXgZry85fBpdvl7HHA8mIE=; b=55H42/oKWB3FUd0Bl6sX1urLe5ROL3xvKlkoK6v8AaSsFtH/kVwnL0k0/FXcHg40gm jypssB/q5Z0IfT+tSZ4kje3f68epAaaKZK+xeo14+jIZ5FRVCQmN2kif0TtZIwIj/CUh loqudjMDa3ujuYNHh5wGaIAC7ocuTfC+lTwTnIBf9PYNJeGq+IbKmsxD5wlp1Muqh8DU s3vym2IdpvYMWXOIIQ0KCM7hL1geJqezzKpsRz2oWvDIKiIyvPm01g1EAfNoOQ7KNBWC Ing9S2Sdkayiodsn2Jn5ponjDG13hRTs9EoXw5N2umhiQTWdGlsTcXaKkdT00luqCMoG eOmg== X-Gm-Message-State: AOAM530cUGikj/TTWyZBHnLCLMcCAi76SUuH6ciUAQ6THqnQ75/CmzlW zxAw0tcJqpalcl6o3TenDbQ= X-Google-Smtp-Source: ABdhPJyH8WJ9REad6nHprPzAYnGaBqDh43GzH0wXC7qBt0Gm/1+2j/aK76u0MxOCqUmdVxJ4CUAPjw== X-Received: by 2002:a63:7d48:0:b0:3db:33fd:b227 with SMTP id m8-20020a637d48000000b003db33fdb227mr7739872pgn.194.1653034395130; Fri, 20 May 2022 01:13:15 -0700 (PDT) Received: from localhost ([134.73.242.163]) by smtp.gmail.com with ESMTPSA id r10-20020a170902e3ca00b00161929fb1adsm4969821ple.54.2022.05.20.01.13.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 May 2022 01:13:14 -0700 (PDT) From: Ihor Radchenko To: Eli Zaretskii Subject: Re: bug#55451: 28.1.50; Executing (jit-lock-mode -1) does not disable jit-lock-mode In-Reply-To: <83mtfdd3ln.fsf@gnu.org> References: <871qwtshk5.fsf@localhost> <83sfp9iie5.fsf@gnu.org> <87bkvwjatb.fsf@gnus.org> <871qwr2hd0.fsf@localhost> <87zgjeagyp.fsf@gnus.org> <83ilq2eo26.fsf@gnu.org> <87czg94opq.fsf@localhost> <83mtfdd3ln.fsf@gnu.org> Date: Fri, 20 May 2022 16:13:58 +0800 Message-ID: <87y1yw39kp.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 55451 Cc: larsi@gnus.org, 55451@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 (/) Eli Zaretskii writes: >> That's exactly the situation I had: >> 1. Tried M-x jit-lock-mode. Did not work. Understandable - special minor >> mode. >> 2. M-: (jit-lock-mode -1). No error. Executed. >> 3. Tried to debug something assuming that jit-lock is disabled. >> 4. After several minutes, realised that jit-lock is still working. > > But the doc string already caters to your use case: > > If you need to debug code run from jit-lock, see `jit-lock-debug-mode' To clarify, I was trying to debug race condition in font-lock itself. jit-lock made things even more complex and I just wanted to quickly disable it. I did not want to debug jit-lock behaviour at all. >> I would not expect users to read minor mode docstring every time to >> check if the usual convention is broken. > > Users don't need to turn off jit-lock. People who want to debug it, > OTOH, _are_ expected to read the doc string. I understand. I do not consider the described issue critical. However, from a perspective of Elisp developer, minor mode docstrings rarely contain low-level information. Rather general minor mode description + standard boilerplate generated by define-minor-mode. That boilerplate is well-known an is usually not worth checking out multiple times: >>> This is a minor mode. If called interactively, toggle the >>> Org-Indent mode mode. If the prefix argument is positive, >>> enable the mode, and if it is zero or negative, disable the mode. >>> >>> If called from Lisp, toggle the mode if ARG is toggle. Enable >>> the mode if ARG is nil, omitted, or is a positive number. >>> Disable the mode if ARG is a negative number. >>> >>> To check whether the minor mode is enabled in the current buffer, >>> evaluate ... So, I would not expect that habituated developers actually check out the docstring regarding enabling/disabling the mode. At least I did not until I realised that something is strange and jit-lock-mode was not disabled after M-: (jit-lock-mode -1) Again, it is just my perspective consisting of a single personal datapoint. If you think that the current state is ok, feel free to disregard my complaint. Best, Ihor From unknown Fri Aug 15 04:04:37 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 17 Jun 2022 11:24:07 +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