From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gleb Zakharov Newsgroups: gmane.emacs.bugs Subject: bug#61923: 30.0.50; go-ts-mode, multiline raw-string-literal wrong indentation Date: Fri, 03 Mar 2023 14:38:19 +0000 Message-ID: <87ttz13nok.fsf@posteo.net> References: <877cvz5b0t.fsf@posteo.net> <83o7paco3n.fsf@gnu.org> <87fsam3wk7.fsf@posteo.net> <83zg8uawu0.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35683"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 61923@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Mar 03 15:39:23 2023 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 1pY6Z8-0008wV-2E for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 03 Mar 2023 15:39:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pY6Yq-0003If-Kb; Fri, 03 Mar 2023 09:39:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pY6Yp-0003IT-Jr for bug-gnu-emacs@gnu.org; Fri, 03 Mar 2023 09:39:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pY6Yp-0002JE-1p for bug-gnu-emacs@gnu.org; Fri, 03 Mar 2023 09:39:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pY6Yo-0001d2-FU for bug-gnu-emacs@gnu.org; Fri, 03 Mar 2023 09:39:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Gleb Zakharov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Mar 2023 14:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61923 X-GNU-PR-Package: emacs Original-Received: via spool by 61923-submit@debbugs.gnu.org id=B61923.16778543096218 (code B ref 61923); Fri, 03 Mar 2023 14:39:02 +0000 Original-Received: (at 61923) by debbugs.gnu.org; 3 Mar 2023 14:38:29 +0000 Original-Received: from localhost ([127.0.0.1]:60020 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pY6YG-0001cD-Vr for submit@debbugs.gnu.org; Fri, 03 Mar 2023 09:38:29 -0500 Original-Received: from mout02.posteo.de ([185.67.36.66]:35999) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pY6YE-0001bx-CP for 61923@debbugs.gnu.org; Fri, 03 Mar 2023 09:38:27 -0500 Original-Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id D45D6240A78 for <61923@debbugs.gnu.org>; Fri, 3 Mar 2023 15:38:20 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1677854300; bh=yjdvhjDIQwAd35OXe1Pnd8+aFGgUwLNjNesqLA6qDWQ=; h=From:To:Cc:Subject:Date:From; b=in4n3rv4DwLLFcrZCauHOXU6eWljMdjV0LH/j3/2Ex7Z1vv8fPL8ou6lTR2V6WR6J twYERp+Oi8mqmabbmDcGIywAciyKraasT+QIV7mtfikZl6VE3YA+TVXlKGZ3OuxmLz gcKGHyx+tmwQxR3x9bzNoiCkXHQcZIoqOjY+ls0KCOzm2o8jo5K8nm0kznfuUhT+YA vwxA5AptQPN8xF3SMsbVPWU9LkzMxIMSKb8eFHSMUcHASRMzdMfE/AQxT/QqNlZ7Ia Yqvng6PyeBWfBNX8yLUhUdoSjXanPsCh+Ql1iFc4vwkz1WjLa838Ps2ErRk79twzqb YbNwiNZf/CpYQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4PSrDr1nmPz9rxH; Fri, 3 Mar 2023 15:38:19 +0100 (CET) In-Reply-To: <83zg8uawu0.fsf@gnu.org> 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:257216 Archived-At: Eli Zaretskii writes: > If you are saying that the indentation inside string is incorrect in > general, then I agree we should fix it. (I don't use Go.) But then > please present the reproduction recipe which doesn't use another > language in the string, but simply has a string, which is corrupted by > indentation. Yes, it seems to be incorrect in general. Sorry for the misguidance regarding language embedding, it is just how I noticed the issue. Here is a recipe of how to reproduce it for a usual piece of text in a scratch buffer with `emacs -Q` : ``` /* (require 'treesit) (require 'go-ts-mode) (setq treesit-extra-load-path '("/home/snyssfx/.guix-home/profile/lib/tree-sitter")) (go-ts-mode) */ func a() { _ = ` Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.` } ``` If we call M-q anywhere in a function or insert a new line in the string literal, the text or its part will be indented. However, the expected behavior is for it to stay as it is. Best Regards, Gleb