From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.devel Subject: Re: Initial fontification in sh-mode with tree-sittter Date: Fri, 28 Oct 2022 01:12:26 -0700 Message-ID: References: Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.120.41.1.1\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25620"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 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 Fri Oct 28 10:13:31 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 1ooKUa-0006UR-N8 for ged-emacs-devel@m.gmane-mx.org; Fri, 28 Oct 2022 10:13:28 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ooKTl-0006Jy-G6; Fri, 28 Oct 2022 04:12:37 -0400 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 1ooKTh-0006IX-0R for emacs-devel@gnu.org; Fri, 28 Oct 2022 04:12:33 -0400 Original-Received: from mail-pj1-x102e.google.com ([2607:f8b0:4864:20::102e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ooKTd-0003c8-7X for emacs-devel@gnu.org; Fri, 28 Oct 2022 04:12:32 -0400 Original-Received: by mail-pj1-x102e.google.com with SMTP id z5-20020a17090a8b8500b00210a3a2364fso7639600pjn.0 for ; Fri, 28 Oct 2022 01:12:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=U0bW7jfFhLPt9g/Pc+MnrJvPPTWMbk2KukYxNVALuyk=; b=E9RnWcBbpDdkqhpfqwnsyMPvDCcKKm9DTe3qjuPP1+CnQWLb+MR56OZprlBYE9wJPd wJrk7LrveuLlczGJ12FEbBAFlpmfc/y7SQLd0kfqgeGgMohS7QD/WcEqw0G9I0t8JZjz 9wR6Irus0RezY0KBUcyv+KKmAYOWUE4gOChPSs6Y1en01ktE+Y65BPo35jv6PAPtSu9S wLKB7E7hlLLhTy8w8AhdIIgcTswZGi88pO9R3EXQT8ARHQs/V8mYfCx+BhZ46D72MK3e y0kJIUthSu5OYB9ulKBy7gC1iLjeJ+vCb/kohCD1Mk/kRmC2L4UDPRjFYyUK61AQvJWO HWHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=U0bW7jfFhLPt9g/Pc+MnrJvPPTWMbk2KukYxNVALuyk=; b=2eLJjC8O//qjsmDwA+MpunVMIIDEhxe6T5DGPj1AIyr9r+s0wH9Vdz8s/L7jdG65kB prU6Mumolgu/kswSgC0anOK4UKhraCKl5RXKbSCN8ZMMfh4SrjwOpFMj8t3KZJxh9yui eC6v5Bc+CO1pCmDobuNxq21gZ21htfvWSYytuyUka1/uP8XmAxCWR1/1vDVaox3xWfXP GijDbheH4QgRI8dzGa6GwZnYU7UdrZjFQziRYJB41L2IeZ4tWg15lxxZjhcqgSSiEgs7 TAidYifxvR9LF+90bfL6KOTrNPPNZqXzfDR9EEAbOGjpkLIGywO2v7mOOF2irr3sd41d Ddvg== X-Gm-Message-State: ACrzQf1mCBlJyX6ZzlQGgwhg143HyXcprhrZAFrjVlqPg//b4OURa/CK /s/6Yu2U0Cxr8djIquNDkL4= X-Google-Smtp-Source: AMsMyM5A1ia3XiJsNO9BdGaLZxaRLed3GRz2vEWq+xX0W2TCOes/vq14899koB8jyuG1Y7yzAA9E+A== X-Received: by 2002:a17:90b:1009:b0:213:9716:20b6 with SMTP id gm9-20020a17090b100900b00213971620b6mr946346pjb.57.1666944747848; Fri, 28 Oct 2022 01:12:27 -0700 (PDT) Original-Received: from smtpclient.apple (cpe-172-117-161-177.socal.res.rr.com. [172.117.161.177]) by smtp.gmail.com with ESMTPSA id f5-20020a170902860500b00186c37270f6sm2415633plo.24.2022.10.28.01.12.27 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 28 Oct 2022 01:12:27 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.3696.120.41.1.1) Received-SPF: pass client-ip=2607:f8b0:4864:20::102e; envelope-from=casouri@gmail.com; helo=mail-pj1-x102e.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: , Original-Sender: "Emacs-devel" Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:298663 Archived-At: > On Oct 27, 2022, at 4:40 PM, Jo=C3=A3o Paulo Labegalini de Carvalho = wrote: >=20 > A similar thing happens on python-mode with tree-sitter enabled. >=20 > Given a buffer with the following code: >=20 > defun foo(): > return 42 >=20 > If a multi-line comment is inserted as in: >=20 > """ > defun foo(): > return 42 > """ >=20 > The function definition does not get fontified as part of a comment. = But if I execute C-x x f, then everything looks good. Now If one of the = markers is deleted, nothing changes until I execute C-x x f, which then = makes everything look correct again. >=20 > It seems that an auto "refreshing" is missing.=20 Hmmm, I couldn=E2=80=99t reproduce this in python-mode, also defun is = not recognized in python so I used this snippet: def foo(): Return 42 When I insert =E2=80=9C=E2=80=9D=E2=80=9D before the defun, everything = after becomes string face, when I insert the following =E2=80=9C=E2=80=9D=E2= =80=9D, everything is updated again. I didn=E2=80=99t make any significant change to the font-lock code = recently, either. Yuan=