From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Joost Kremers Newsgroups: gmane.emacs.devel Subject: Re: cc-mode fontification feels random Date: Fri, 04 Jun 2021 22:11:06 +0200 Message-ID: <8735txfkk7.fsf@fastmail.fm> References: <831r9iw473.fsf@gnu.org> <87h7ieyma7.fsf@gmail.com> <15be7dd8-e901-e317-5111-e1a34f6f0416@gmail.com> <83k0n9l9pv.fsf@gnu.org> <83eedhl83r.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29625"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.5.12; emacs 27.2.50 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jun 04 22:24:14 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 1lpGMY-0007RD-7H for ged-emacs-devel@m.gmane-mx.org; Fri, 04 Jun 2021 22:24:14 +0200 Original-Received: from localhost ([::1]:57698 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lpGMX-0007ML-8N for ged-emacs-devel@m.gmane-mx.org; Fri, 04 Jun 2021 16:24:13 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39774) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lpGJY-0001kI-PV for emacs-devel@gnu.org; Fri, 04 Jun 2021 16:21:08 -0400 Original-Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:32945) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lpGJU-0002IX-3m for emacs-devel@gnu.org; Fri, 04 Jun 2021 16:21:08 -0400 Original-Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.west.internal (Postfix) with ESMTP id 452BE15D6 for ; Fri, 4 Jun 2021 16:21:01 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute5.internal (MEProxy); Fri, 04 Jun 2021 16:21:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= references:from:to:subject:date:in-reply-to:message-id :mime-version:content-type; s=fm3; bh=58R/VxCCvimL5UtjSKQ+j9jIag KuWWGF4zLFtQ4oBQQ=; b=BVOXhVQo8fTvpFHzEutPVf9cs2V8VukRlPLDRblPpT hTRLra1chCEHREowh2egU3T6WjJ2Sln4H9AJfCl4+bTHUJyyXerkct8EGglBLS1M ttJ8EZCbqI5VD8aj7RwYxNFI7O93SYWCzEqnfIfZ5By4vaScWDsLPLTr+A53EDBo t3GI+8SsirfDdvxoHNdvGNEQTpaYbn7O2TyyPBy15Dwlks5Zz9XM9PLH6azlJvNk TcEqgM4L18p/C/BLbeWhmuS64aW5LOwO51laxNGWz4ZS08urWvkPQMuFUaDE4xkO 4fCNUsYkCv3Za7U909bpW6qbPm4hmRjShYscHrvSo5zw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=58R/Vx CCvimL5UtjSKQ+j9jIagKuWWGF4zLFtQ4oBQQ=; b=T2ES2v+HVQRSGzDWFKBXxO n1pk4WRtgwQv+j64jJVTt0XEqPLP4tcZUOjlsZKwAw92Amlf6cibA3idWn0WzAbB anWeWbBAdE0Xyqi/kYLXVM9RoWKxRFs1t5o9B3S02N5GhRMObtDqXdm1ZcbH9ERw fYhMm059Uq3tVJqIp48uGNDpiDaByL+xWkdR4wyjA3plKNNDmws3prprPMO9oPsW TcDeUDXBKtTurzYmCF0yB0PojSIyyYbkc6+blHPSGDzKls3RxQbAwjbqtFzuzfLm pNS57iQNQ4umfA239LYoLDhtNPeZjNfTDqnpOcLgWbPPPeisGKrPwq/wbE5c+Prg == X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrfedtuddgudegjecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecunecujfgurhepfhgfhffvufffjgfkgggtsehttd ertddtredtnecuhfhrohhmpeflohhoshhtucfmrhgvmhgvrhhsuceojhhoohhsthhkrhgv mhgvrhhssehfrghsthhmrghilhdrfhhmqeenucggtffrrghtthgvrhhnpedviefhteeuve ekudetheduieehvdelgfeijeehvdetfeegleelhefhjeduieejveenucevlhhushhtvghr ufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehjohhoshhtkhhrvghmvghrsh esfhgrshhtmhgrihhlrdhfmh X-ME-Proxy: Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA for ; Fri, 4 Jun 2021 16:21:00 -0400 (EDT) In-reply-to: Received-SPF: pass client-ip=64.147.123.25; envelope-from=joostkremers@fastmail.fm; helo=wout2-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-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.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:270411 Archived-At: On Fri, Jun 04 2021, Jim Porter wrote: > On Fri, Jun 4, 2021 at 12:53 PM Eli Zaretskii wrote: >> Why does it do that? Does the LSP server have to access the file >> itself? We have all the contents of that file locally in a buffer, so >> we could hand it to LSP locally. > > I'm not an expert on the internals of LSP servers, but it's my > understanding that for a language server like clangd, it needs access > not just to the current file, but the entire source tree[1]. And speaking from my experience with lsp-mode (not eglot) and Python, it needs access to the entire virtual env so it can provide type information and completions for built-in Python packages and for 3rd-party packages that you use your code. -- Joost Kremers Life has its moments