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: `M-q' uses tree-sitter now? Date: Sun, 18 Dec 2022 20:37:54 +0200 Message-ID: <834jtsfth9.fsf@gnu.org> References: <5B81ABF1-29FA-4624-A091-533363344CF1@thornhill.no> <838rj4fx86.fsf@gnu.org> <6CBF6ED9-1ECB-4313-B5E2-3CE66931CDEB@thornhill.no> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33739"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org, eduardoochs@gmail.com To: Theodor Thornhill Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Dec 18 19:38:22 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 1p6yYI-0008d1-81 for ged-emacs-devel@m.gmane-mx.org; Sun, 18 Dec 2022 19:38:22 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p6yXl-0008HU-Cu; Sun, 18 Dec 2022 13:37:49 -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 1p6yXj-0008H1-A6 for emacs-devel@gnu.org; Sun, 18 Dec 2022 13:37:47 -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 1p6yXi-00006M-TJ; Sun, 18 Dec 2022 13:37:46 -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=i27G6163xawGIgvnnvLTxBASvnclI5Su+X4xLwnldao=; b=WBNVM/5o4IAV zFtEqrTy5pY6eO8jOEg+V7fl7ffT6X2aF8qkLvpmUU2rtOY+f2xFBQ09gQI7ad+Z5VOEoSwDbq2T3 bh/Z9i66ztSxpDi/CaCfb8GbbmB7d+0N2TCbONP1T0nSYL5FPXRJCsK7pCBPZgXPv6HrEmXkSpfeb RnBRlTZTbZSc2ZNyZes2nlZWaMwwDK+LkBOoLwFmMfY7RZ/SM0oD+hffy3K5JQtUFItQoL+mJHaDt NQTWfo1iS1S+W//G2gq0IRafe80rmYPVaPWCYU3jM0fG0Z/tDwyZXmKlSFYFie8jcm993MCSgRNhe RirNTeCE6T8cSUVUE7goOQ==; 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 1p6yXi-0004X5-6m; Sun, 18 Dec 2022 13:37:46 -0500 In-Reply-To: <6CBF6ED9-1ECB-4313-B5E2-3CE66931CDEB@thornhill.no> (message from Theodor Thornhill on Sun, 18 Dec 2022 19:08:30 +0100) 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:301617 Archived-At: > Date: Sun, 18 Dec 2022 19:08:30 +0100 > From: Theodor Thornhill > CC: emacs-devel@gnu.org, eduardoochs@gmail.com > > > > On 18 December 2022 18:16:57 CET, Eli Zaretskii wrote: > >> Date: Sun, 18 Dec 2022 15:53:29 +0100 > >> From: Theodor Thornhill > >> > >> Strange. Shouldn't it be enough to put the require in the eval-when-compile? Is anything else needed for the function to be picked up? > > > >His Emacs was built without tree-sitter, would be my guess. We need > >to call treesit-available-p when this can happen, before calling any > >treesit functions that might not be fboundp. > > Right, makes sense. I guess this can occur other places as well. I can look around and see if it's needed other places. Please do, and thanks.