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#72765: Eglot + Clangd + Company + non-empty suffix = duplicate text Date: Mon, 09 Sep 2024 14:46:09 +0300 Message-ID: <867cblvym6.fsf@gnu.org> References: <83e5b9c4-0f5f-49c4-a4b2-fe553c59b2f6@gutov.dev> <86o75bftql.fsf@gnu.org> <119819e3-fc54-4f9a-9075-b07af637db12@gutov.dev> <864j71dw8e.fsf@gnu.org> <48e0fa23-623e-4a73-b968-ba10d766cf37@gutov.dev> <87y14bwvyd.fsf@gmail.com> <9a5884da-44cc-4f9a-9d4a-caf830617c7f@gutov.dev> <6805f597-20ab-4c97-b1bf-1b15856364e0@gutov.dev> <76a2f902-5876-42a3-ad06-b95d6a9959c1@gutov.dev> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17161"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 72765@debbugs.gnu.org, joaotavora@gmail.com To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Sep 09 13:47:27 2024 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 1sncre-0004Mu-EJ for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 09 Sep 2024 13:47:26 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sncrP-0000qI-CJ; Mon, 09 Sep 2024 07:47:11 -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 1sncrD-0000KF-Aj for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 07:46:59 -0400 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 1sncrD-0002Pb-0V for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 07:46:59 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=2KarlsKmqOI/Zie50pmYSALl1pMVvgwl+GwpWI0G5o8=; b=l7MTU/G2kuiC4D/ceYaBOmgiiBKlQYbIJFDgPDIrTIcnpsCgAD+2HnAqwhVXsOQf3xc26rEZPVhYTTDjn8k7cm8L351w6zILmLq3X2o9rmqN5PjrvgYdZhd/K/fsjAoHAYAN+TakTVc0tMkUzJ+OOOyXIK0LWoonFB2S7lbrc6hIPH3+V9X574VV1rp/hK4X6VqozFIMe8TxBj1T4GLubHPvOWw/Tk4Pie8PUgkmU/1Nhjk3GWGlLEAoqXhFtDPlnpy1LgCJQ5dXUSv48Wgc74YTRVrPuBQcru4tKC22Cj92WnDAoKZUWzGYT1nXFU49qLfe+DjB87W1laN4yRrUqg==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sncrG-0000Dv-3d for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 07:47:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 09 Sep 2024 11:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72765 X-GNU-PR-Package: emacs Original-Received: via spool by 72765-submit@debbugs.gnu.org id=B72765.1725882385806 (code B ref 72765); Mon, 09 Sep 2024 11:47:02 +0000 Original-Received: (at 72765) by debbugs.gnu.org; 9 Sep 2024 11:46:25 +0000 Original-Received: from localhost ([127.0.0.1]:60805 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sncqe-0000Cv-QO for submit@debbugs.gnu.org; Mon, 09 Sep 2024 07:46:25 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:37338) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sncqb-0000CQ-KQ for 72765@debbugs.gnu.org; Mon, 09 Sep 2024 07:46:23 -0400 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 1sncqS-0002No-LU; Mon, 09 Sep 2024 07:46:12 -0400 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=Auc8ZMiChQjc7JTIkn6C1doUvl00FAdPLN/A8RCME9o=; b=UOj40EYkrbcz Vso9hQFSuLcWPSiUEi678o2wW1rotWEu3JrYfN/fqmtWhrmHubkEYOBYBH1f+cTFdJA6VSBBg9VZz W0B3XjeOaqF6ICkdkvQhWOX4VJdfZUKulY3pPyw4x4aYOgYmDe2YGSFylxbIO0VR42Y6VrJfGk63w AoDVGfv8BwanlRe3wIH1q9QvK+/PNx07i0fn9Xl18vQwmaK8/VrQZ0MxLPoeYQ+vmyDovLbv09HCX psP4hyeaq26A6hBBmGASPG6/w4Dcq0XKmrbetbvjPM2GGRdvZO6xrumsvyTa+DAtUpedjODzLcZxF I6GadWrC6rPnHBYfacW3Ow==; In-Reply-To: <76a2f902-5876-42a3-ad06-b95d6a9959c1@gutov.dev> (message from Dmitry Gutov on Mon, 9 Sep 2024 03:20:01 +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:291496 Archived-At: > Date: Mon, 9 Sep 2024 03:20:01 +0300 > Cc: Eli Zaretskii , 72765@debbugs.gnu.org > From: Dmitry Gutov > > > This now aborts (segfault?). At least something different. > > > > So, for the record, before this patch with the latest emacs-30, I get the > > results in failure1.txt and with your last redisplay-skip-initial-frame patch > > I get failure2.txt. > > > > I've produced these files with > > > > make -C test eglot-tests SELECTOR=\"rust-completion\" 2>&1 | tee failure1.txt > > So it's reproducible. Great! > > Could someone look into the segfault? The repro steps are simple: > > 1) apply the patch above, > 2) run 'make -C test eglot-tests' or the longer command above which > executes just one test from that file. > > The backtrace that I managed to generate is attached. Thanks. Please try the patch below. P.S. I'm not at all sure this is the last segfault you will see because you are playing with fire: you are not supposed to reset redisplay-skip-initial-frame to nil in batch-mode tests that test redisplay-related features! diff --git a/src/xdisp.c b/src/xdisp.c index bf7d84c..a1319e7 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -22089,7 +22089,8 @@ #define GIVE_UP(X) return 0 /* Window must either use window-based redisplay or be full width. */ if (!FRAME_WINDOW_P (f) - && (!FRAME_LINE_INS_DEL_OK (f) + && (FRAME_INITIAL_P (f) + || !FRAME_LINE_INS_DEL_OK (f) || !WINDOW_FULL_WIDTH_P (w))) GIVE_UP (4);