From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Initial fontification in sh-mode with tree-sittter Date: Sun, 13 Nov 2022 08:23:05 +0200 Message-ID: <83edu7mkza.fsf@gnu.org> References: <6C8B0F8E-DF61-4BC3-B0D0-56DBB66BE637@gmail.com> <7AE71CCA-6F18-4DE6-8608-7D9B3E9E52FB@gmail.com> <9BA853EA-8B7F-41A0-A174-D86DF5CE7788@gmail.com> <83sfj3cfl0.fsf@gnu.org> <03309451-1AEB-458C-88FD-9715CECC27A2@gmail.com> <83mt9bc9ke.fsf@gnu.org> <8335b19ndr.fsf@gnu.org> <39ECD413-BD10-4BF3-90AC-36F02276607E@gmail.com> <8A2361BB-1081-4550-AC29-B9E99BFC2FB8@gmail.com> <42DBD4F5-71D9-434E-B7B4-4E0FF89F934F@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21515"; mail-complaints-to="usenet@ciao.gmane.io" Cc: casouri@gmail.com, emacs-devel@gnu.org To: =?utf-8?Q?Jo=C3=A3o?= Paulo Labegalini de Carvalho Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Nov 13 07:23:46 2022 Return-path: Envelope-to: ged-emacs-devel@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 1ou6PC-0005Rb-7G for ged-emacs-devel@m.gmane-mx.org; Sun, 13 Nov 2022 07:23:46 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ou6OU-0004Ts-0n; Sun, 13 Nov 2022 01:23:02 -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 1ou6OS-0004Ta-4i for emacs-devel@gnu.org; Sun, 13 Nov 2022 01:23:00 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ou6OR-00013o-Mq; Sun, 13 Nov 2022 01:22:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=0sehgMqNCpoVyVWo6NEkoKxhRdMn1dX/p696dGmJkT8=; b=dyp/RcGmTh16NAqBnRoQ Koln1iOqKMNlx+mq920OezeSivj5OoSfAO/hC2rvI/PAjP5N6AZ+pld3jOv1ziyOQJi8/7TutZido UbxVYRYzEp00e7FGD7hCP9ro3jh2r2qi7AfE0j1sjtxv4J/FwBcJHYiCcHkVWpLzmwG6UN58DngQ1 qOknx3o3nWwMn3VAAR135GoKpN0VqkZuxHNJ6+h+ElqmBbhSonSnt7TWh3pXoeFfJ662KAOX6DMhM TB4tGtHuVxG6kHrqX+Ws4riY52RBsdhKM4Fk+pIrypEx5ogz7f/jPMuaVHx1a6E1EwFNH0uK1pr22 W0tDUDAa3hNZzQ==; Original-Received: from [87.69.77.57] (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 1ou6OQ-000113-Q7; Sun, 13 Nov 2022 01:22:59 -0500 In-Reply-To: (message from =?utf-8?Q?Jo=C3=A3o?= Paulo Labegalini de Carvalho on Sat, 12 Nov 2022 15:04:26 -0700) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:299700 Archived-At: > From: João Paulo Labegalini de Carvalho > Date: Sat, 12 Nov 2022 15:04:26 -0700 > Cc: Eli Zaretskii , emacs-devel@gnu.org > > I see. This is tree-sitter-bash’s problem. When there are only newlines between two EOF’s, the parser > erroneously marks everything that follows as heredoc_body. I tried tree-sitter’s online demo and it gives > the same result[1]. We should report this to tree-sitter-bash’s author. > > Sorry for the delay. I confirmed the problem was in the tree-sitter-bash side and submitted a PR to fix it: > https://github.com/tree-sitter/tree-sitter-bash/pull/137 > Once my fixes are pulled in, there is no change required to my patch. Do we need to wait for their fix, or can we have code that will start working correctly when they fix the parser?