From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#41649: 27.0.91; beginning-of-defun doesn't work inside React markup in js-jsx-mode Date: Wed, 3 Jun 2020 00:43:32 +0300 Message-ID: <0cbfd145-bdb2-4e1c-2f81-864c55894bc2@yandex.ru> References: <20200602171221.19097.qmail@mail.muc.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="41916"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 Cc: 41649@debbugs.gnu.org To: Alan Mackenzie , Brian Leung Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jun 02 23:44:14 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 1jgEhg-000AnP-LG for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 02 Jun 2020 23:44:12 +0200 Original-Received: from localhost ([::1]:50878 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jgEhf-0004Iy-Kn for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 02 Jun 2020 17:44:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47030) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jgEhW-0004In-8n for bug-gnu-emacs@gnu.org; Tue, 02 Jun 2020 17:44:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:57847) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jgEhV-0006rt-W1 for bug-gnu-emacs@gnu.org; Tue, 02 Jun 2020 17:44:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jgEhV-00051L-U8 for bug-gnu-emacs@gnu.org; Tue, 02 Jun 2020 17:44:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 02 Jun 2020 21:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41649 X-GNU-PR-Package: emacs Original-Received: via spool by 41649-submit@debbugs.gnu.org id=B41649.159113422219267 (code B ref 41649); Tue, 02 Jun 2020 21:44:01 +0000 Original-Received: (at 41649) by debbugs.gnu.org; 2 Jun 2020 21:43:42 +0000 Original-Received: from localhost ([127.0.0.1]:41160 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jgEhC-00050h-Cy for submit@debbugs.gnu.org; Tue, 02 Jun 2020 17:43:42 -0400 Original-Received: from mail-wr1-f48.google.com ([209.85.221.48]:38479) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jgEhA-00050U-Nm for 41649@debbugs.gnu.org; Tue, 02 Jun 2020 17:43:41 -0400 Original-Received: by mail-wr1-f48.google.com with SMTP id e1so181739wrt.5 for <41649@debbugs.gnu.org>; Tue, 02 Jun 2020 14:43:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=RTDLEE3XOvSv6ZvZUVlJ2qZ1T0RGM3yp5s7lJ+GtIrU=; b=QhSAH3hd3xhFgiPgMXI0YgmV1sTsMT1wlmWBFK1bWJc5peib1YKIgeJqoXZ0MV4p/O Ye4tw8AVoGDTssxQr9E0896Fp6jjQbNXW5lHvqGIEjwlHYIKBnStBBN7pyqsn3jKHOIV /JMUIfDWiLXc25SnRUu/vxacsBQQsU0nyOyhmY2bLPoWEqy+HejY3Qt0p8peoWCll0nq jMcSXQE57m0N6BDGb9u0KyAtQDMf8Sw1yzBScQP/xU9uFZryP9LYKonnZaiQ1H/2bEds Mjh3eGGaaDn+nwiGUWVJVUfkZc0VvVbXG1cXbD4Srqc4IwLSCnNegYif6Vt4SqQ2Wtmg j5+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=RTDLEE3XOvSv6ZvZUVlJ2qZ1T0RGM3yp5s7lJ+GtIrU=; b=jpJRbxSd4Seang9Go3AWFsji7uEwLi/Wodf3AYvxumuTepA4IlfYLBdIKGVqIfH9zt l389QwtW0GTblYxVH7ilv6gOtyOphSErqMJKqFv5ZFvTBpZnuBnpfM2rJZqA6Sg5cb92 ag0ikWqYIGs2RlfrOquZHuInSYGUNBzKVej89duDtS4PxY6NJgi9dsAxzK0IFzVcnwpL V5btEaQDq03XHouvPeRKdSAtiQWKjmvJUGTRc0yOSCKvnlenPHrW1VryBzIlQkf5T92A oo1kqThp6GygYWKbwrwEkwocAw7H2ImfRsjlbQBSsutdjThC//JdK1jqI6jfXR1DeZ4M MOvw== X-Gm-Message-State: AOAM5308oPTM8eHbAx0foQMKqLPoEsLFVOniHOHAL7Ra31Nduq2xRwPH k9Mlxjzcmm49ezC6oJuaGuY1oAaI X-Google-Smtp-Source: ABdhPJzgG0dokX+UuiBQ4Lmf0rX2CUwKDEYUOmHCM9pxEO5Qizlzf/zqTeHbQnuUF4LEw3N9a9+mWg== X-Received: by 2002:a5d:5092:: with SMTP id a18mr27848268wrt.42.1591134214576; Tue, 02 Jun 2020 14:43:34 -0700 (PDT) Original-Received: from [192.168.0.3] ([66.205.73.129]) by smtp.googlemail.com with ESMTPSA id n189sm150629wmb.43.2020.06.02.14.43.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 02 Jun 2020 14:43:34 -0700 (PDT) In-Reply-To: <20200602171221.19097.qmail@mail.muc.de> Content-Language: en-US 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:181430 Archived-At: Hi Alan, On 02.06.2020 20:12, Alan Mackenzie wrote: > The problem seems to stem from the top-level function #'js-mode. Early > on, it invokes > > (c-init-language-vars js-mode) > > , which initialises the CC Mode language variables to (mostly) their > Java Mode values. js-mode continues by overwriting the local value of > quite a few of these variables, including beginning-of-defun-function. > > js-mode then invokes > > (c-init-language-vars js-mode) > > a second time, which initialises the language variables again, in > particular, those variables which just got a local value, including > beginning-of-defun-function. > > Daniel, what is going on, here? Is this just a simple coding error, > where the second c-init-language-vars should have been removed at some stage? I agree that the second call should be removed. You might be amused to look at the commit 4ad6c932a82, though, and see who the author is. :-)