From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jim Porter Newsgroups: gmane.emacs.devel Subject: Re: cc-mode fontification feels random Date: Fri, 4 Jun 2021 12:41:56 -0700 Message-ID: References: <831r9iw473.fsf@gnu.org> <87h7ieyma7.fsf@gmail.com> <15be7dd8-e901-e317-5111-e1a34f6f0416@gmail.com> <83k0n9l9pv.fsf@gnu.org> Mime-Version: 1.0 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="6082"; mail-complaints-to="usenet@ciao.gmane.io" Cc: ubolonton@gmail.com, dancol@dancol.org, theo@thornhill.no, joaotavora@gmail.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jun 04 21:42:42 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 1lpFiM-0001Qg-SK for ged-emacs-devel@m.gmane-mx.org; Fri, 04 Jun 2021 21:42:42 +0200 Original-Received: from localhost ([::1]:52270 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lpFiL-0005eP-Rg for ged-emacs-devel@m.gmane-mx.org; Fri, 04 Jun 2021 15:42:41 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59856) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lpFhq-0004xZ-Im for emacs-devel@gnu.org; Fri, 04 Jun 2021 15:42:10 -0400 Original-Received: from mail-pg1-x52e.google.com ([2607:f8b0:4864:20::52e]:47003) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lpFho-0002Zt-Un; Fri, 04 Jun 2021 15:42:10 -0400 Original-Received: by mail-pg1-x52e.google.com with SMTP id n12so8645355pgs.13; Fri, 04 Jun 2021 12:42:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=afQ5Seao3Tjgsn1prov/QvmrhERI8FCNFDTJTe3wGNI=; b=T82nrjoUTAysXmzYd7s0u00ZgmAeb2NECFnud10XZlIdsR5BXBabc8Q//IVp+AKZLb hmAq2Cg4KkVPnH784C0OuIq3I1gbS8wf8GzM+5Ir0GmmZRqXoc0v1d+GzkClZ/Wr2+tk 8fHETadPFGKCDNu7g2YPXxkRe5dp+HgKpeL+AarRXaKCPjDbbFGHfl4xVFcGC0DPaTog tVM9l+urmvqnnvoLaxQquBGQJ+RFjUZAJ/C/kFB0jUivFSI/fec/wUhIHhjw/eA6xSYX Y1I4uMGPFwchCX/SYvAqA8O1fZnvFGj3GS1fqCqd4CVd+1PRQS9WUAtKX0X9oedNTQVm b9vA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=afQ5Seao3Tjgsn1prov/QvmrhERI8FCNFDTJTe3wGNI=; b=EuY9+8frntUOK3mXF7MgSoIpT4UoFG8BTUSFlhr8XDwjTgg2MRnxU8Q+Y39owEwMSS +RDfbpZwt+L549eTh5ZOjQRKFxIyBPdzk8KMjRTuXaRlT9ax81mMK23sL8/F2tNP1Vj7 68Fxfwen+2Rt0ziUe/E+vurEG1yUW6xi6U4E6i/u/ZyVkOQCCnM/qTGkwGrqahJxSNMM oTDWUx1Tu9alt3Yniy17liBRNiyutPq2YmL7HBKcV+HyQ52twMb+C0hiLQWmJ7OIuT4I rADobdPuSDzDvFDOmNF3lYDIWsKx9qM5SPcR9QRy722Bofpx0WEXlcMmthzTDh/Vxs6I qXNg== X-Gm-Message-State: AOAM5301FVulo0VHDVebbJ2UT2dmHT5Y2mTiYcRn6c6hm+7eVkfkySCk EFYqqbe/VU0NoBJF+Mc3/2Ohi7SMfzLW5HS62V0/MWLKBd8= X-Google-Smtp-Source: ABdhPJyeoLZ0ACAo1cLed37x67K0bpJgQ555t7XhsH7jRrR3yJZRxZG2c5YhOcuBiVo68drBNDc1+ZwzxkHjDpWT2ek= X-Received: by 2002:a62:190e:0:b029:2e3:3522:2232 with SMTP id 14-20020a62190e0000b02902e335222232mr6078256pfz.4.1622835727118; Fri, 04 Jun 2021 12:42:07 -0700 (PDT) In-Reply-To: <83k0n9l9pv.fsf@gnu.org> Received-SPF: pass client-ip=2607:f8b0:4864:20::52e; envelope-from=jporterbugs@gmail.com; helo=mail-pg1-x52e.google.com X-Spam_score_int: -10 X-Spam_score: -1.1 X-Spam_bar: - X-Spam_report: (-1.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, FREEMAIL_REPLY=1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action 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:270406 Archived-At: (Note: re-adding emacs-devel here, since I posted through Gmane and attempted to eliminate dupe messages by posting only to the Gmane mirror and not mailing the list directly. That was backwards, and I should have removed the Gmane mirror, or perhaps just ignored the issue and let the mailing list handle dupes.) On Fri, Jun 4, 2021 at 12:18 PM Eli Zaretskii wrote: > > > Cc: Eli Zaretskii , Daniel Colascione = , > > ubolonton@gmail.com > > From: Jim Porter > > Date: Fri, 4 Jun 2021 09:43:26 -0700 > > > > On 6/4/2021 3:08 AM, Jo=C3=A3o T=C3=A1vora wrote: > > > - However, LSP support for fontification seems like it's potentially > > > _less_ efficient than integrating something like tree-sitter as a = C > > > module in Emacs. That's because the contents of the buffer and > > > fontification results are continually transmitted back and forth v= ia > > > pipes and JSON format. > > > > I imagine these potential performance issues would also be exacerbated > > by editing over TRAMP. > > Why? Fontification is always local, even if the files you edit are on > a remote host. The way I understand this particular hypothetical is that Eglot would be responsible for asking the LSP server for syntax highlighting and would then do the necessary work to tell Emacs how to fontify the buffer. Currently, the way Eglot works for remote files is that it runs the LSP server on the remote host via TRAMP. That works out nicely right now, but if we wanted to get the syntax highlighting from the (remote) LSP server to the (local) Emacs instance, that data would have to go through TRAMP. I'm not sure how much data we're talking about here, but if there are performance concerns about doing this locally via pipes, it would be exacerbated by going through a slow network. - Jim