From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Fernando de Morais Newsgroups: gmane.emacs.bugs Subject: bug#61479: 28.2; icomplete-in-buffer --- Error in post-command-hook: args-out-of-range Date: Sat, 25 Feb 2023 09:15:51 -0300 Message-ID: <87sfeuj5zc.fsf@gmail.com> References: <87y1p1wr4m.fsf@gmail.com> <86cz6dfnyu.fsf@mail.linkov.net> <87wn4ltpg0.fsf@gmail.com> <87lel0ao9z.fsf@gmail.com> <86wn4k14pt.fsf@mail.linkov.net> <87y1p0dovd.fsf@gmail.com> <868rgxea6c.fsf@mail.linkov.net> <875ybz2jiw.fsf@gmail.com> <86ttzckaxm.fsf@mail.linkov.net> 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="40746"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 61479@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Feb 25 13:17:47 2023 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 1pVtUn-000A4d-VY for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 25 Feb 2023 13:17:45 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pVtUA-0003Nx-G4; Sat, 25 Feb 2023 07:17:06 -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 1pVtU7-0003NO-2R for bug-gnu-emacs@gnu.org; Sat, 25 Feb 2023 07:17:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pVtU6-0000Ai-QP for bug-gnu-emacs@gnu.org; Sat, 25 Feb 2023 07:17:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pVtU6-0002yS-Bo for bug-gnu-emacs@gnu.org; Sat, 25 Feb 2023 07:17:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Fernando de Morais Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 25 Feb 2023 12:17:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61479 X-GNU-PR-Package: emacs Original-Received: via spool by 61479-submit@debbugs.gnu.org id=B61479.167732740511402 (code B ref 61479); Sat, 25 Feb 2023 12:17:02 +0000 Original-Received: (at 61479) by debbugs.gnu.org; 25 Feb 2023 12:16:45 +0000 Original-Received: from localhost ([127.0.0.1]:39308 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pVtTo-0002xp-O6 for submit@debbugs.gnu.org; Sat, 25 Feb 2023 07:16:45 -0500 Original-Received: from mail-oo1-f42.google.com ([209.85.161.42]:43893) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pVtTm-0002xa-Ux for 61479@debbugs.gnu.org; Sat, 25 Feb 2023 07:16:43 -0500 Original-Received: by mail-oo1-f42.google.com with SMTP id a23-20020a4ad5d7000000b005250867d3d9so308224oot.10 for <61479@debbugs.gnu.org>; Sat, 25 Feb 2023 04:16:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:user-agent:references :message-id:date:in-reply-to:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=Gpf/5bmYjJOfXJ3MtbJgW2xclHK9v0Kzais0KjC0WHI=; b=SxesV86AD3UuImAmM8cdjM63kGGzey3AfwAqO8tUtVVlauonwctqhHRFjfv3mDI4F1 vyAWG+I0kTxxiggrAYA/ZzoIof58NXNlcz8mULDsCq0QaMNLqSAvgLOSHgpuATr3UoH6 dthkjovkirGPvOjSlG4QV/bfd/nJ3qONkMd7Pu6gy8kCt3vWrT3VoMmqDczm3dqQAcT6 27QNtIlUgGt4hE7Zn/uzeP05mp0d+WSs73OYOtPsrgJz8GNEYPKei8R5u3Wz3TBPRlbZ FB4kgWrWGLdB2HryHBU+mN1oOyRiXdv9yliljSesXLOB3qPMfNVw/KTUmwrcNmKKXuRV EJxA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:user-agent:references :message-id:date:in-reply-to:subject:cc:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=Gpf/5bmYjJOfXJ3MtbJgW2xclHK9v0Kzais0KjC0WHI=; b=QV+bgW8mbmRKp3+La8trYQnKDXczDZeMjj8OPbm6lWszWNH1xY3XCx1yVyIyjr0wjT fbv4vswEWTlsQ5IO5h0D1bZOq8UEcwVwwOk0E3Dfn+iOGxA+UqkzoQd/UcTgqp1YXR81 GMO9qQ/ZEFcz2ExDKtclKrTAbqgRDvFlcZSF2Wenfuc9K0nPvdV3zuDM9Bb3rjCeCL79 bhIgk1f2Erq5yUweOgIiJUe7Jx4jZFtTG1gMIzkWZIqH54XNpzbHzCzrBQLBcHj3DyVo 4SGIbivWJTQzNd6dfam8MvgcOVnPJp9J/wJPELbvEARsYIGLscPTnQ64fjw7NlcA6kpx gpYQ== X-Gm-Message-State: AO0yUKWpEzjGEm90pIlzwbkcdUpURBeV39CVB8r3wmnPjdhOrkrEXMzA vkmrpXm/wEhQdlcVEijb469YpvC6MSc= X-Google-Smtp-Source: AK7set/xDiu6T/1MhhExndLmn8PxAty9bwMhvYw7tIhvR81SQCznSZ4pRWFS6jmfDtaVbpRtfiFd5w== X-Received: by 2002:a4a:3456:0:b0:517:4020:60b6 with SMTP id n22-20020a4a3456000000b00517402060b6mr7843011oof.8.1677327396982; Sat, 25 Feb 2023 04:16:36 -0800 (PST) Original-Received: from sekai ([2804:14c:da80:82e2::925f]) by smtp.gmail.com with ESMTPSA id a16-20020a9d6e90000000b0068bdfa56717sm554296otr.36.2023.02.25.04.16.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 25 Feb 2023 04:16:36 -0800 (PST) In-Reply-To: <86ttzckaxm.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 23 Feb 2023 10:36:45 +0200") 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:256713 Archived-At: Hello Juri, Juri Linkov writes: > This shows that C-M-i bound to icomplete-force-complete needs the same > treatment: > > diff --git a/lisp/icomplete.el b/lisp/icomplete.el > index f7a91599f3b..b0b55dd1e7e 100644 > --- a/lisp/icomplete.el > +++ b/lisp/icomplete.el > @@ -215,7 +215,11 @@ icomplete-force-complete-and-exit > ;; calculated, This causes the first cached completion to > ;; be taken (i.e. the one that the user sees highlighted) > completion-all-sorted-completions) > - (minibuffer-force-complete-and-exit) > + (if (window-minibuffer-p) > + (minibuffer-force-complete-and-exit) > + (minibuffer-force-complete (icomplete--field-beg) > + (icomplete--field-end) > + 'dont-cycle)) > ;; Otherwise take the faster route... > (minibuffer-complete-and-exit))) >=20=20 > @@ -223,7 +227,11 @@ icomplete-force-complete > "Complete the icomplete minibuffer." > (interactive) > ;; We're not at all interested in cycling here (bug#34077). > - (minibuffer-force-complete nil nil 'dont-cycle)) > + (if (window-minibuffer-p) > + (minibuffer-force-complete nil nil 'dont-cycle) > + (minibuffer-force-complete (icomplete--field-beg) > + (icomplete--field-end) > + 'dont-cycle))) >=20=20 > ;; Apropos `icomplete-scroll', we implement "scrolling icomplete" > ;; within classic icomplete, which is "rotating", by contrast. I've tested it and it worked perfectly! Thank you once more. > Thanks for finding another way to reproduce the problem. You're welcome. =F0=9F=A4=9D --=20 Regards, Fernando de Morais.