From unknown Thu Aug 14 21:45:33 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#15582 <15582@debbugs.gnu.org> To: bug#15582 <15582@debbugs.gnu.org> Subject: Status: js-mode indent bug Reply-To: bug#15582 <15582@debbugs.gnu.org> Date: Fri, 15 Aug 2025 04:45:33 +0000 retitle 15582 js-mode indent bug reassign 15582 emacs submitter 15582 Jakub Jankiewicz severity 15582 minor thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 10 08:38:32 2013 Received: (at submit) by debbugs.gnu.org; 10 Oct 2013 12:38:32 +0000 Received: from localhost ([127.0.0.1]:39992 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VUFVg-0004Jg-C4 for submit@debbugs.gnu.org; Thu, 10 Oct 2013 08:38:32 -0400 Received: from eggs.gnu.org ([208.118.235.92]:58948) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VUFVd-0004JW-NE for submit@debbugs.gnu.org; Thu, 10 Oct 2013 08:38:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VUFVY-0002GO-33 for submit@debbugs.gnu.org; Thu, 10 Oct 2013 08:38:29 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_40,FREEMAIL_FROM, T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:57432) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUFVY-0002GK-01 for submit@debbugs.gnu.org; Thu, 10 Oct 2013 08:38:24 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60647) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUFVS-0007eF-Rk for bug-gnu-emacs@gnu.org; Thu, 10 Oct 2013 08:38:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VUFVN-0002EZ-Nx for bug-gnu-emacs@gnu.org; Thu, 10 Oct 2013 08:38:18 -0400 Received: from smtpo13.poczta.onet.pl ([213.180.142.144]:34746) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VUFVN-0002EI-Ch for bug-gnu-emacs@gnu.org; Thu, 10 Oct 2013 08:38:13 -0400 Received: from jcubic (atf96.neoplus.adsl.tpnet.pl [83.26.243.96]) (using SSLv3 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: jcubic@onet.pl) by smtp.poczta.onet.pl (Onet) with ESMTPSA id 3cwWHw2ljBzZCl4R for ; Thu, 10 Oct 2013 14:07:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=onet.pl; s=2011; t=1381406828; bh=OxT6Esh5BsXdvc6KZBAzuwdXvNM1Si0EW9McVIYjt3o=; h=Date:From:To:Subject:Message-ID:Mime-Version:Content-Type; b=jIzB4bIzryOWf56sn8GLPlvIWF0maYkK2OZSAFlZGgX8Udx9XEsCOKng6UE9ga0Us jXKsXvZIHuD1MNFSDVKqqgNOWrurlLqAYIXCaTPDakYyOWv2thF58aQHDs9Wr5aK6o lRklGWGk2ZR2rCnnWTdwfNqccwP7UKWl0YSRO5/U= Date: Thu, 10 Oct 2013 14:06:48 +0200 From: Jakub Jankiewicz To: bug-gnu-emacs@gnu.org Subject: js-mode indent bug Message-ID: <20131010140648.2d3d1c4a@jcubic> X-Mailer: Claws Mail 3.8.1 (GTK+ 2.24.17; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/A3KcM7NXVoT=VvE7iDsYk1q"; protocol="application/pgp-signature" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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: -4.1 (----) --Sig_/A3KcM7NXVoT=VvE7iDsYk1q Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi, I found this bug in js-mode indent: when you have multiline if statement with comment at the end, next line indent is doubled. If I have js-indent-level equal 8 the code look like this: if (x > left && x < left + image.width && y > top && y < top + image.height) { do_somethig(); } but when I put comment after if it look like this: if (x > left && x < left + image.width && y > top && y < top + image.height) { // found do_somethig(); when js-indent-level is 2 it have 4 spaces. The same is with while while (10 && 20) { // asd xx(); four spaces instead of two version: GNU Emacs 24.2.1 -- Jakub Jankiewicz, Web Developer http://jcubic.pl --Sig_/A3KcM7NXVoT=VvE7iDsYk1q Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQEcBAEBAgAGBQJSVphZAAoJEKWO5vEx+DATU10H/jODBJqpuBTZlmb6Bno2iv/U ZJZqCexk7yBFuqGirFSg61s5bENgGaRdU4s+6X21RMU+ShA/KQMZffNBRnAm3o4v LU1/DgmLPDv96RLnvS5G1aSNa91SsZZdaUAkG4uRA5ipvGwyVqFbENkh9y0I8pUt ZMGy1T4ITnlW+0Qia8ie9RLCtlcVHpiiBm9c4w+XFXQTRcLWhmmICqxXbeS7FDg7 8QBROGXCHdjFyV9lpQiL0bh1bdhBsfXAp5TdT1tzMqsU6QJDDIngphMys0O1BHmg RELbCermLlZWxu3ft0BEFyBAuYPJmOV/whxW2H3m37yDOYRctHtC5rII85RNWAk= =TGnG -----END PGP SIGNATURE----- --Sig_/A3KcM7NXVoT=VvE7iDsYk1q-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 10 00:04:17 2017 Received: (at 15582) by debbugs.gnu.org; 10 Jan 2017 05:04:17 +0000 Received: from localhost ([127.0.0.1]:48331 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cQobZ-0003oA-7j for submit@debbugs.gnu.org; Tue, 10 Jan 2017 00:04:17 -0500 Received: from gproxy9-pub.mail.unifiedlayer.com ([69.89.20.122]:52473 helo=gproxy9.mail.unifiedlayer.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cQobX-0003nx-3V for 15582@debbugs.gnu.org; Tue, 10 Jan 2017 00:04:15 -0500 Received: from cmgw4 (unknown [10.0.90.85]) by gproxy9.mail.unifiedlayer.com (Postfix) with ESMTP id 371771E0AFA for <15582@debbugs.gnu.org>; Mon, 9 Jan 2017 22:04:05 -0700 (MST) Received: from box522.bluehost.com ([74.220.219.122]) by cmgw4 with id WV411u01H2f2jeq01V440w; Mon, 09 Jan 2017 22:04:05 -0700 X-Authority-Analysis: v=2.1 cv=SY5kKJhu c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=IgFoBzBjUZAA:10 a=Zx47kWw7-Z4Ii6z4YucA:9 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:Date:CC:Subject:To:From; bh=W04XmmF6XtnVAduead8mfEMEkVXqneAfQz4ByCadvyw=; b=W5Hod61TsYKnffabgKWCZqZzo dDcxnAhQwHO+TmQALiZjgFE2g+W2wTuw9cwbojHEnpJwvUIc40zmbRovw/ZVAoRgqt1Ch/oNF78/5 Rj4OUUgGIayB5gkBKElJ/CTigt; Received: from 174-16-146-181.hlrn.qwest.net ([174.16.146.181]:55362 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.86_1) (envelope-from ) id 1cQobJ-0003Ze-Hu; Mon, 09 Jan 2017 22:04:01 -0700 From: Tom Tromey To: 15582@debbugs.gnu.org Subject: notes on js-mode indentation bug X-Attribution: Tom Date: Mon, 09 Jan 2017 22:03:59 -0700 Message-ID: <87fukr1p6o.fsf@tromey.com> MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box522.bluehost.com X-AntiAbuse: Original Domain - debbugs.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 174.16.146.181 X-Exim-ID: 1cQobJ-0003Ze-Hu X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 174-16-146-181.hlrn.qwest.net (bapiya) [174.16.146.181]:55362 X-Source-Auth: tom+tromey.com X-Email-Count: 1 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-Spam-Score: -1.1 (-) X-Debbugs-Envelope-To: 15582 Cc: Daniel Colascione 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.1 (-) I looked into this bug. With the comment, js--continued-expression-p returns t, causing js--proper-indentation to take this branch of a cond: (continued-expr-p (+ (current-column) (* 2 js-indent-level) js-expr-indent-offset)) Without the comment, this doesn't happen, so I think the problem here is that js--continued-expression-p returns t. Digging into this a bit more, the issue is that js--re-search-backward moves point to the wrong newline, because the newline at the end of the "//" comment is rejected. This patch works by introducing a new js--find-newline-backward that tries to do the right thing for line comments. I've included a new test case (as a patch to a file first appearing in another pending patch), but considering that there aren't any other indentation tests for js-mode, I think some review is necessary. It would be helpful to know when the continued-expr-p branch really is supposed to trigger. Or, if there is an informal corpus of indentation tests, it would be nice to put them all into js-tests.el. Tom diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el index 1484b79..0551f2a 100644 --- a/lisp/progmodes/js.el +++ b/lisp/progmodes/js.el @@ -1771,6 +1771,24 @@ js--looking-at-operator-p ;; return NaN anyway. Shouldn't be a problem. (memq (char-before) '(?, ?} ?{)))))))) +(defun js--find-newline-backward () + "Move backward to the nearest newline that is not in a block comment." + (let ((continue t) + (result t)) + (while continue + (setq continue nil) + (if (re-search-backward "\n" nil t) + (let ((parse (syntax-ppss))) + ;; We match the end of a // comment but not a newline in a + ;; block comment. + (when (nth 4 parse) + (goto-char (nth 8 parse)) + ;; If we saw a block comment, keep trying. + (unless (nth 7 parse) + (setq continue t)))) + (setq result nil))) + result)) + (defun js--continued-expression-p () "Return non-nil if the current line continues an expression." (save-excursion @@ -1780,7 +1798,7 @@ js--continued-expression-p (progn (forward-comment (- (point))) (not (memq (char-before) '(?, ?\[ ?\())))) - (and (js--re-search-backward "\n" nil t) + (and (js--find-newline-backward) (progn (skip-chars-backward " \t") (or (bobp) (backward-char)) diff --git a/test/lisp/progmodes/js-tests.el b/test/lisp/progmodes/js-tests.el index 9bf7258..de322f2 100644 --- a/test/lisp/progmodes/js-tests.el +++ b/test/lisp/progmodes/js-tests.el @@ -59,6 +59,16 @@ * Load the inspector's shared head.js for use by tests that need to * open the something or other")))) +(ert-deftest js-mode-indent-bug-15582 () + (with-temp-buffer + (js-mode) + (setq-local js-indent-level 8) + (insert "if (x > 72 &&\n y < 85) { // found\n\t") + (save-excursion (insert "do_something();\n")) + (js-indent-line) + (should (equal (buffer-substring (point-at-bol) (point-at-eol)) + "\tdo_something();")))) + (provide 'js-tests) ;;; js-tests.el ends here From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 13 22:51:34 2017 Received: (at 15582) by debbugs.gnu.org; 14 Jan 2017 03:51:35 +0000 Received: from localhost ([127.0.0.1]:53241 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cSFNO-00051r-Oj for submit@debbugs.gnu.org; Fri, 13 Jan 2017 22:51:34 -0500 Received: from mail-lf0-f67.google.com ([209.85.215.67]:35278) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cSFNN-00051f-1b for 15582@debbugs.gnu.org; Fri, 13 Jan 2017 22:51:33 -0500 Received: by mail-lf0-f67.google.com with SMTP id v186so7521046lfa.2 for <15582@debbugs.gnu.org>; Fri, 13 Jan 2017 19:51:32 -0800 (PST) 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=mZd+OmoYW0U4P3sIWDqABDuOCjY0TtGuqyCODbA6RCA=; b=gL+I3il/cH8bPlsSgzITaMjVK8ui79GaAEeobmt8KkhXkb0PR8RPTet+ULqpaMwVoF I73oK8K+v2oERuOQ//TXvmFhhaFTlbyBB9oZNRjrDKYBgUgkKvUkwJpv60gOtXjP8fv1 yL5InwmJli21nC4dMHilB7qZPKtSl15Ic5YBdytQGSrS1HFgBelb74fu8jMCyUSvMG49 7M4MHpMU5+N2RUy/kKINZedm0VslduQw9y2f0YaqyuENMVWTfUTZQeRiMX1o5VMLtbKx HX81xANfi+DHm7mRtrFlxNHL5DvmgZGyMawbULQ8lRj71bn9AFKDvwpGtDWKlxpNVU2q 7wUg== 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=mZd+OmoYW0U4P3sIWDqABDuOCjY0TtGuqyCODbA6RCA=; b=tAI+bShz6Y49dXm0A+rm9J7LXcHfl9E519q3GVqeAIPIPL7qamElaQ7haQ92k6l7lr TjI9h/imyZx8FAJdIEG/+YrhqAImvr3biB7axfQFQzGgQGPZbQI0EjHzmhaVJG2ddk5r WAn+noqnPl1oBNGAVcIapSEAtaLEPMPdT8twHp4cDoUVsLGV2dtgJrQhIXZu3CRSaBG/ SGvL3izPEvhVoUqp2p/72ndhBe4QScb9a8BrM4bAenZu6SuisiqsExxGHVuu+UKKDnCE EzIRICnIBJZW7RoxTHY/NYwtCVksnGWSTYvgpR2z5wGA9rvSQNrEjBhYOuvXU6CESzNN efSw== X-Gm-Message-State: AIkVDXKkoQuZkC5KT0iSp4h25nxFhApjeMA3Pr3jE9UxG4tSr8Ce5BZWdPpANzH7z4XCoQ== X-Received: by 10.25.44.66 with SMTP id s63mr8879446lfs.159.1484365887111; Fri, 13 Jan 2017 19:51:27 -0800 (PST) Received: from [192.168.1.174] ([178.252.127.239]) by smtp.googlemail.com with ESMTPSA id g95sm4633329lfi.9.2017.01.13.19.51.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Jan 2017 19:51:26 -0800 (PST) Subject: Re: bug#15582: notes on js-mode indentation bug To: Tom Tromey , 15582@debbugs.gnu.org References: <20131010140648.2d3d1c4a@jcubic> <87fukr1p6o.fsf@tromey.com> From: Dmitry Gutov Message-ID: Date: Sat, 14 Jan 2017 06:51:25 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:51.0) Gecko/20100101 Thunderbird/51.0 MIME-Version: 1.0 In-Reply-To: <87fukr1p6o.fsf@tromey.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 4.1 (++++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.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 the administrator of that system for details. Content preview: On 10.01.2017 08:03, Tom Tromey wrote: > It would be helpful to know when the continued-expr-p branch really is > supposed to trigger. Or, if there is an informal corpus of indentation > tests, it would be nice to put them all into js-tests.el. [...] Content analysis details: (4.1 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.5 RCVD_IN_SORBS_SPAM RBL: SORBS: sender is a spam source [209.85.215.67 listed in dnsbl.sorbs.net] 3.6 RCVD_IN_SORBS_WEB RBL: SORBS: sender is an abusable web server [178.252.127.239 listed in dnsbl.sorbs.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [209.85.215.67 listed in list.dnswl.org] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (dgutov[at]yandex.ru) -0.0 SPF_PASS SPF: sender matches SPF record -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [209.85.215.67 listed in wl.mailspike.net] 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders 0.0 T_DKIM_INVALID DKIM-Signature header exists but is not valid X-Debbugs-Envelope-To: 15582 Cc: Daniel Colascione 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: 4.1 (++++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.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 the administrator of that system for details. Content preview: On 10.01.2017 08:03, Tom Tromey wrote: > It would be helpful to know when the continued-expr-p branch really is > supposed to trigger. Or, if there is an informal corpus of indentation > tests, it would be nice to put them all into js-tests.el. [...] Content analysis details: (4.1 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.5 RCVD_IN_SORBS_SPAM RBL: SORBS: sender is a spam source [209.85.215.67 listed in dnsbl.sorbs.net] 3.6 RCVD_IN_SORBS_WEB RBL: SORBS: sender is an abusable web server [178.252.127.239 listed in dnsbl.sorbs.net] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [209.85.215.67 listed in wl.mailspike.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [209.85.215.67 listed in list.dnswl.org] 0.0 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (dgutov[at]yandex.ru) -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FORGED_FROMDOMAIN 2nd level domains in From and EnvelopeFrom freemail headers are different -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders 0.0 T_DKIM_INVALID DKIM-Signature header exists but is not valid On 10.01.2017 08:03, Tom Tromey wrote: > It would be helpful to know when the continued-expr-p branch really is > supposed to trigger. Or, if there is an informal corpus of indentation > tests, it would be nice to put them all into js-tests.el. It triggers, for instance, in this example: b += c But you have probably found it already. > Tom > > diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el > index 1484b79..0551f2a 100644 > --- a/lisp/progmodes/js.el > +++ b/lisp/progmodes/js.el > @@ -1771,6 +1771,24 @@ js--looking-at-operator-p > ;; return NaN anyway. Shouldn't be a problem. > (memq (char-before) '(?, ?} ?{)))))))) > > +(defun js--find-newline-backward () > + "Move backward to the nearest newline that is not in a block comment." You might want to phrase it like "Move ... ignoring comments.", meaning treating the openers of non-block comments as newlines, and the contents of block comments as entirely invisible. BTW, here are a couple of examples that the new fix doesn't handle: b += /* found */ c b += /* */ c (I think they suggest that the block comment-related behavior of the new function might be tweaked a little). Thanks. From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 14 12:46:07 2017 Received: (at 15582-done) by debbugs.gnu.org; 14 Jan 2017 17:46:07 +0000 Received: from localhost ([127.0.0.1]:54106 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cSSP1-0000dH-A5 for submit@debbugs.gnu.org; Sat, 14 Jan 2017 12:46:07 -0500 Received: from gproxy3-pub.mail.unifiedlayer.com ([69.89.30.42]:53479) by debbugs.gnu.org with smtp (Exim 4.84_2) (envelope-from ) id 1cSSP0-0000by-56 for 15582-done@debbugs.gnu.org; Sat, 14 Jan 2017 12:46:06 -0500 Received: (qmail 22140 invoked by uid 0); 14 Jan 2017 17:45:55 -0000 Received: from unknown (HELO CMOut01) (10.0.90.82) by gproxy3.mail.unifiedlayer.com with SMTP; 14 Jan 2017 17:45:55 -0000 Received: from box522.bluehost.com ([74.220.219.122]) by CMOut01 with id YHlo1u00e2f2jeq01Hlru1; Sat, 14 Jan 2017 10:45:54 -0700 X-Authority-Analysis: v=2.1 cv=H75InYoi c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=IgFoBzBjUZAA:10 a=1rtpgCSgDIRRoX6YSpQA:9 a=SNtjo_lfmOkA:10 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From: Sender:Reply-To:Cc: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=7H9/1kJWc1YlTMbpZXpHbPmioj9mkQ6HDVMNSBbCV9o=; b=XJMGt7Ov/TyDwSUnXxpCXhVWko Ib7PRz49VucKtWAzSbiHOWWmcH8wxGcwW1u6ohLte//3PD+iUOvRhOkAF6EvKbApKz5Wh7+N0BgS7 5tRAkOU+xClroHwpQnGU3vifD; Received: from 174-16-146-181.hlrn.qwest.net ([174.16.146.181]:54004 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87) (envelope-from ) id 1cSSOj-0004iL-NM; Sat, 14 Jan 2017 10:45:49 -0700 From: Tom Tromey To: 15582-done@debbugs.gnu.org Subject: done X-Attribution: Tom Date: Sat, 14 Jan 2017 10:45:44 -0700 Message-ID: <878tqd4jsn.fsf@tromey.com> MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box522.bluehost.com X-AntiAbuse: Original Domain - debbugs.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 174.16.146.181 X-Exim-ID: 1cSSOj-0004iL-NM X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 174-16-146-181.hlrn.qwest.net (bapiya) [174.16.146.181]:54004 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-Spam-Score: -0.6 (/) X-Debbugs-Envelope-To: 15582-done 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.6 (/) This was fixed by b47f97218efb8d9966e084bdfd8a86e8c47cf81d. Tom From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 16 11:12:50 2017 Received: (at 15582) by debbugs.gnu.org; 16 Jan 2017 16:12:50 +0000 Received: from localhost ([127.0.0.1]:55877 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cT9tq-0007DN-Js for submit@debbugs.gnu.org; Mon, 16 Jan 2017 11:12:50 -0500 Received: from gproxy9-pub.mail.unifiedlayer.com ([69.89.20.122]:57000 helo=gproxy9.mail.unifiedlayer.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cT9tn-0007D8-TL for 15582@debbugs.gnu.org; Mon, 16 Jan 2017 11:12:48 -0500 Received: from cmgw3 (unknown [10.0.90.84]) by gproxy9.mail.unifiedlayer.com (Postfix) with ESMTP id ED9D81E0CE2 for <15582@debbugs.gnu.org>; Mon, 16 Jan 2017 09:12:39 -0700 (MST) Received: from box522.bluehost.com ([74.220.219.122]) by cmgw3 with id Z4BN1u0032f2jeq014BRk9; Mon, 16 Jan 2017 09:11:25 -0700 X-Authority-Analysis: v=2.1 cv=YuCcGeoX c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=IgFoBzBjUZAA:10 a=QViPybCz7UPWsFiRaegA:9 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; 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=kh5jqE8dDiCA/3hVG4zITmeb/T6K+7D+Ca34ofdHkbw=; b=e72giWg3kFZoK402GaX/z21LKE mGC2ASUWjieAiqcS7LdifxxjHXbjaMMc2SyT/7vFCmYMrGX0lGbFSm6H0YbTTj/A3v4/kWxaIVcJb CDqK++LjLORxwBfoDbIcw/lHo; Received: from 174-16-146-181.hlrn.qwest.net ([174.16.146.181]:57302 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87) (envelope-from ) id 1cT9sP-0000K9-RH; Mon, 16 Jan 2017 09:11:21 -0700 From: Tom Tromey To: Dmitry Gutov Subject: Re: bug#15582: notes on js-mode indentation bug References: <20131010140648.2d3d1c4a@jcubic> <87fukr1p6o.fsf@tromey.com> X-Attribution: Tom Date: Mon, 16 Jan 2017 09:11:17 -0700 In-Reply-To: (Dmitry Gutov's message of "Sat, 14 Jan 2017 06:51:25 +0300") Message-ID: <87r3432dei.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.90 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box522.bluehost.com X-AntiAbuse: Original Domain - debbugs.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 174.16.146.181 X-Exim-ID: 1cT9sP-0000K9-RH X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 174-16-146-181.hlrn.qwest.net (bapiya) [174.16.146.181]:57302 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-Spam-Score: -0.6 (/) X-Debbugs-Envelope-To: 15582 Cc: 15582@debbugs.gnu.org, Tom Tromey , Daniel Colascione 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.6 (/) Dmitry> BTW, here are a couple of examples that the new fix doesn't handle: Thanks. I'll try to fix these. Tom From unknown Thu Aug 14 21:45:33 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, 14 Feb 2017 12: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