From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Augusto Stoffel Newsgroups: gmane.emacs.devel Subject: Re: Tree-sitter integration in python.el Date: Fri, 07 Oct 2022 12:03:42 +0200 Message-ID: <87wn9c7xxd.fsf@gmail.com> References: <3A68545C-2E40-4BB4-8563-8041A5452634@gmail.com> <87y1twlr0v.fsf@gmail.com> <83czb8ycpo.fsf@gnu.org> <87tu4klfcw.fsf@gmail.com> <87ill0le20.fsf@gmail.com> <87y1ttfmj8.fsf@gmail.com> <19950F30-F4DB-4CE4-9257-24DA39594669@gmail.com> <87czb47jya.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29361"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Matthias Meulien , Eli Zaretskii , emacs-devel@gnu.org To: Yuan Fu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Oct 07 12:09:08 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 1ogkHz-0007Uq-Mx for ged-emacs-devel@m.gmane-mx.org; Fri, 07 Oct 2022 12:09:07 +0200 Original-Received: from localhost ([::1]:44802 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ogkHy-0006FJ-A2 for ged-emacs-devel@m.gmane-mx.org; Fri, 07 Oct 2022 06:09:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53636) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ogkCt-0004IT-0r for emacs-devel@gnu.org; Fri, 07 Oct 2022 06:03:51 -0400 Original-Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]:41545) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ogkCr-0004pO-Ba; Fri, 07 Oct 2022 06:03:50 -0400 Original-Received: by mail-ej1-x634.google.com with SMTP id qw20so9581640ejc.8; Fri, 07 Oct 2022 03:03:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=FSDZNk89CEsZTx+JZN61jymJH9oXvnOS4E3Hd2gpZ9k=; b=p1ftrOJ+0/udJ+mmPl+wK2+GrCxiDAUjC3qrTdoAulBqPH9e/MVidvg5jCg/NH7Gw2 ekal1efxz84nZR+IklnayoWF+96ZHX2SCoIXJTUo/ZLCk4TRU2ZRAL5R8RUT9mYmuiSa 27efFbn1IFKZmNvCg3Khry0+fk6OpwMl9ED8mnHQwgl/7J5gunGPOE1BnNKMKYHVXw+M NDJJeJI3X2KYW8PXlzw7Oqg3DwbO3h6TCSWfTReJEyVnIChmIIes0piIew361sFkWFbB 5ZX0oaPsusiBjsM3Y1WaWL1dEZFotAIsuQ5xyxtN+lcnafmIcF/BzgVOQ4onnPsifAc/ TLvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=FSDZNk89CEsZTx+JZN61jymJH9oXvnOS4E3Hd2gpZ9k=; b=EnLxu8rhOkSKaYE6edsfYXbQXWist6ZNt4po/HNCBIo0NlCgn6/B147vdutwa14xwX biXuOKJpRtIuUFJsUvskc/vn5Rd+Hqkf5jJUj1GhsfKWq1vr924TUkJyrWdVtXgIrCr9 SgF5iIl5Xacl0N1Mci8WW7EMPud2lsgUmXiDmYDusL1STsIas5DX5sykpB3YBC2HXo5B 6u614OY2MgnofFllkB7Fe/vh1BYbGaYCQuIZRVyLLVgdpQYh5mGVzYoA6D33ArpqHhNh FNLTa24Lti/7npUIYWc2f9JOmdzT04p1WtQSn4iQ26LUzaThf/FKbcbclN4yQGyfwu5Y 2kmQ== X-Gm-Message-State: ACrzQf3zBmS+I0r+QKjTj7fkg4Q41ATGjRHZxRJIy2SQqzcsGPwT2DjT 1yBC+/13BmNC7LQZG2wxNrN7thLklg4= X-Google-Smtp-Source: AMsMyM7bG2/HFro+7SRdTb4tb3wbfvBzx1oW2pw720zxwGuBciGp47ki4NuwMZSEFVVI+XwyFAK9cQ== X-Received: by 2002:a17:906:7952:b0:787:a14d:65a7 with SMTP id l18-20020a170906795200b00787a14d65a7mr3539590ejo.108.1665137023980; Fri, 07 Oct 2022 03:03:43 -0700 (PDT) Original-Received: from ars3 ([2a02:8109:8ac0:56d0::89aa]) by smtp.gmail.com with ESMTPSA id u19-20020a170906b11300b007803083a36asm963486ejy.115.2022.10.07.03.03.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 07 Oct 2022 03:03:43 -0700 (PDT) In-Reply-To: (Yuan Fu's message of "Fri, 7 Oct 2022 01:25:27 -0700") Received-SPF: pass client-ip=2a00:1450:4864:20::634; envelope-from=arstoffel@gmail.com; helo=mail-ej1-x634.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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" Xref: news.gmane.io gmane.emacs.devel:297142 Archived-At: On Fri, 7 Oct 2022 at 01:25, Yuan Fu wrote: > Yeah, with tree-sitter, fortifying types is trivial. In fact all types > should be fortified already. (I tested with some simple examples.) > Should we provide some variables to toggle fontification for different > things? Like python-fontify-type/f-string/assignment/built-in/etc. Looking at the screenshots posted a few messages back, which are VERY busy, I would really appreciate an option to disable a few fontification rules or, conversely, disable all but a few of them. Ideally, this should be done through a generic mechanism that works across major modes. Have you seen the new `font-lock-ignore' option? Tree-sitter could provide something similar (and much better/less hacky).