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.bugs Subject: bug#67061: [PATCH] Improve syntax highlighting for python-ts-mode Date: Sat, 11 Nov 2023 09:32:48 +0200 Message-ID: <831qcwycbj.fsf@gnu.org> References: <8734xdni6y.fsf@yandex.ru> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2845"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 67061@debbugs.gnu.org To: Denis Zubarev , Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Nov 11 08:33:52 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 1r1iV6-0000Wo-Fc for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 11 Nov 2023 08:33:52 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r1iUf-00067R-1z; Sat, 11 Nov 2023 02:33:25 -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 1r1iUc-000663-EB for bug-gnu-emacs@gnu.org; Sat, 11 Nov 2023 02:33:23 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r1iUc-0006BN-5q for bug-gnu-emacs@gnu.org; Sat, 11 Nov 2023 02:33:22 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1r1iVG-00081I-Ac for bug-gnu-emacs@gnu.org; Sat, 11 Nov 2023 02:34:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 11 Nov 2023 07:34:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67061 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 67061-submit@debbugs.gnu.org id=B67061.169968802530796 (code B ref 67061); Sat, 11 Nov 2023 07:34:02 +0000 Original-Received: (at 67061) by debbugs.gnu.org; 11 Nov 2023 07:33:45 +0000 Original-Received: from localhost ([127.0.0.1]:51414 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r1iUy-00080e-L3 for submit@debbugs.gnu.org; Sat, 11 Nov 2023 02:33:44 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53292) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1r1iUw-00080Q-Cb for 67061@debbugs.gnu.org; Sat, 11 Nov 2023 02:33:43 -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 1r1iUC-00068G-2t; Sat, 11 Nov 2023 02:32:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=U70Lbe/VLSxPaSFr5g4SzMLChY8yKVUkP8sMvXCkY40=; b=TnhzmEqMCg+1 m8vu95MJXIO+dR1WaG2laleacfV+PuV9NeJZlFkq2M0j1DuN0hs3ZMHXZMeZH3ff/Rd9k1+MBm5cg 4x6ju+yYwSJGD86op9dcd8VzI6dUBtuu2Qutnajwyxeut7bdkERWSGsbUzjqdSQYOECTiJwPBpTqU ag8eEhPsZqJPnZnIiWT02WPt+w5OJ02+ebgjjtKab+Te9z2QWBmN3M+PTWMFP3a3nMYXBE/ud6yPE Zuung+msRiF499Hg+lW/Vpf/7mV9W4v3nBgAWLk/udRP9LLi7BIbHCF4DS7f3bqfrLl9y1tFSqRFP Lm0/LOu8zE1rGjW3FxC6zw==; In-Reply-To: <8734xdni6y.fsf@yandex.ru> (message from Denis Zubarev on Sat, 11 Nov 2023 05:21:25 +0300) 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:274141 Archived-At: > From: Denis Zubarev > Date: Sat, 11 Nov 2023 05:21:25 +0300 > > Improve syntax highlighting for python-ts-mode. > > - Fontify compound keywords "not in" and "is not" (fixes bug#67015) > - Fix fontification of strings inside of f-strings interpolation, > e.g. for f"beg {'nested'}" - 'nested' was not fontified as string. > - Do not override the face of builtin functions (all, bytes etc.) with > the function call face > - Add missing assignment expressions > - Fontify built-ins (dict,list,etc.) as types when they are used in type hints Yuan, any comments? My only comment is that we should decide in which fontification level(s) should the additional fontifications be. > I have added tests to treesit-tests.el, but I'm not sure that it is the > right place for them. I tried to create new file > python-ts-mode-tests.el, but when I run tests using make, I got > an error: > *** No rule to make target '../lisp/progmodes/python-ts-mode.el', needed by 'lisp/progmodes/python-ts-mode-tests.log'. Stop. > > It seems that python-ts-mode is required to be in its own file, but it > is defined in python.el. > Adding tests to python-tests.el seems like not good idea too, because > some CI code is searching for *-ts-mode-tests.el or treesit-tests.el files. The tests should be in python-tests.el, and should be skipped if (treesit-ready-p 'python t) returns nil. What problems with CI did you see? I don't think I understand your last sentence above. > >From 0b3165eb90bdc1b85688d3c9a1902c1f293972d1 Mon Sep 17 00:00:00 2001 > From: Denis Zubarev > Date: Sat, 11 Nov 2023 04:55:44 +0300 > Subject: [PATCH] Improve syntax highlighting for python-ts-mode This submission is too large for us to accept without a copyright assignment. Would you like to start your assignment copyright paperwork rolling at this time? If yes, I will send you the form to fill and the instructions to email it. Thanks.