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: cc-mode fontification feels random Date: Sat, 12 Jun 2021 11:13:49 +0300 Message-ID: <83mtrv8pqa.fsf@gnu.org> References: <83o8cge4lg.fsf@gnu.org> <62e438b5-d27f-1d3c-69c6-11fe29a76d74@dancol.org> <83fsxsdxhu.fsf@gnu.org> <83pmwudgw3.fsf@gnu.org> <20210610151647.qtt7pqbjhdtp6coe@Ergus> <20210611202130.j35q6k4utjivzuen@Ergus> <9e76076e-636d-9271-03e2-98c7614e3cf1@dancol.org> <83v96j8tsl.fsf@gnu.org> <179ff3ee6d8.2816.cc5b3318d7e9908e2c46732289705cb0@dancol.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26672"; mail-complaints-to="usenet@ciao.gmane.io" Cc: spacibba@aol.com, rms@gnu.org, emacs-devel@gnu.org, rudalics@gmx.at, monnier@iro.umontreal.ca, acm@muc.de To: Daniel Colascione Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Jun 12 10:14:56 2021 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 1lrynA-0006kO-GS for ged-emacs-devel@m.gmane-mx.org; Sat, 12 Jun 2021 10:14:56 +0200 Original-Received: from localhost ([::1]:45444 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lryn9-0005lR-IA for ged-emacs-devel@m.gmane-mx.org; Sat, 12 Jun 2021 04:14:55 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52928) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lrymL-0004kC-RE for emacs-devel@gnu.org; Sat, 12 Jun 2021 04:14:05 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:35418) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lrymK-0003Qm-PF; Sat, 12 Jun 2021 04:14:04 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:4447 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 1lrymD-00052N-CV; Sat, 12 Jun 2021 04:13:59 -0400 In-Reply-To: <179ff3ee6d8.2816.cc5b3318d7e9908e2c46732289705cb0@dancol.org> (message from Daniel Colascione on Sat, 12 Jun 2021 01:03:03 -0700) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.io gmane.emacs.devel:270747 Archived-At: > From: Daniel Colascione > CC: , , , , > Date: Sat, 12 Jun 2021 01:03:03 -0700 > > >> Yes, there are some technical disadvantages to tree-sitter, indeed. > >> None of them make it unusable, but they do make it less convenient for > >> ELisp hackers and Emacs users. So it's not a perfect solution, but > >> I don't think that should mean we don't want it in our toolbox. > > > > I agree that these issues shouldn't prevent us from trying to use TS, > > at least as an option. > > Sure, but it'd be nice to package TS in such a way that it becomes more > idiomatically lispy, at least if TS becomes the primary fontification > engine for some modes. At the very least, it should be possible for users > to apply ad hoc fontification on top of whatever TS supports. I agree. Do you consider these goals impractical for some reason? If not, then (assuming we otherwise like the results of using TS in Emacs) we could work towards those goals as followup. > And how could something like TS work with, say, bison and flex files > without fully general multi-mode support (which we also lack)? Good question. Shouldn't limiting TS to the relevant portions of buffer text provide the solution? If not, perhaps we should ask the TS folks what they suggest.