From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Martin Marshall Newsgroups: gmane.emacs.bugs Subject: bug#68487: [PATCH] Make jump commands usable for all skeletons Date: Tue, 06 Feb 2024 17:11:59 -0500 Message-ID: <87il316y4w.fsf@martinmarshall.com> References: <877ckawckc.fsf@martinmarshall.com> <875xz2y46o.fsf@martinmarshall.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24687"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 68487@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Feb 06 23:12:59 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 1rXTgZ-0006FS-6k for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 06 Feb 2024 23:12:59 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXTgR-0007mp-IL; Tue, 06 Feb 2024 17:12:51 -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 1rXTgP-0007mV-FI for bug-gnu-emacs@gnu.org; Tue, 06 Feb 2024 17:12:49 -0500 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 1rXTgP-0002yO-6f for bug-gnu-emacs@gnu.org; Tue, 06 Feb 2024 17:12:49 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rXTgc-0005jR-7S for bug-gnu-emacs@gnu.org; Tue, 06 Feb 2024 17:13:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Martin Marshall Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 06 Feb 2024 22:13:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68487 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 68487-submit@debbugs.gnu.org id=B68487.170725754621974 (code B ref 68487); Tue, 06 Feb 2024 22:13:02 +0000 Original-Received: (at 68487) by debbugs.gnu.org; 6 Feb 2024 22:12:26 +0000 Original-Received: from localhost ([127.0.0.1]:55290 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXTg1-0005iL-Mw for submit@debbugs.gnu.org; Tue, 06 Feb 2024 17:12:25 -0500 Original-Received: from mail-yb1-xb2c.google.com ([2607:f8b0:4864:20::b2c]:61887) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXTfx-0005i5-E1 for 68487@debbugs.gnu.org; Tue, 06 Feb 2024 17:12:24 -0500 Original-Received: by mail-yb1-xb2c.google.com with SMTP id 3f1490d57ef6-dc6d9a8815fso5875145276.3 for <68487@debbugs.gnu.org>; Tue, 06 Feb 2024 14:12:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=martinmarshall-com.20230601.gappssmtp.com; s=20230601; t=1707257522; x=1707862322; darn=debbugs.gnu.org; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=t+qTg4T8udZRO4BbJq8Cfr4bFKqDWAvHRT7Fl1Kyssk=; b=KPlawkomrDVha3Oosi90lZmhriSULqZ4GVCOjlsQLpbyUW1Ol7f10/we6Uu9wFcycD JSy8APoHXkbenf4yQNSgnosIeB5JaXi5abpbRFJh65Azqp9drryrkLlB3i1htuZDYPmn eTJoi1UtdTB9pDDqguNgpsGhJMKScfIpQQtl+opLkbHk1DddbgRoz3bQMvA0O5abIY13 6VMB0OyV4dAXx+WBFjNWJxlVRoy6tzB1AP/FLUysN7SibY+8Ic75jbuVUFKiIAZOknzc sKsSV2Kp9rehMCZ4XsIMqyKC0iqx8SDsGV5WIUeQRxoxI7vwj0loYyyX/0jd7DzZoUqr I4qQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707257522; x=1707862322; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=t+qTg4T8udZRO4BbJq8Cfr4bFKqDWAvHRT7Fl1Kyssk=; b=J/YTWkECVvEH/q4QtR1ud6l+kQf2TylNbi1iUoyBYi1ENoiKNArpG2v/giSWjGW6Gf yKfYA9F4D2XhrOX4QniaWXDKMPnjfikAazAnq3X3nJ0DN+gEn7gK9Y/2yC3s+Bc83JuQ a4wRRgmtt4UIcaGSbLsDbzOUevyTmthxDXXgbj8X6J9TnKDsLxIWHO0cqCuh/4ZvBib0 vnKlSBgqie95CFhYgLbg8JiKi5ywHsKN0KoEo+/hOaOZ1oa4Z9YxO3Hi9tc7xofBvxue Ykt4sE/QMr6pN/yD+f5z5t5BOEOFOxh4540YarNfo4yq2wBpTmJ7tdwxN9+gF2AJBQ0x vIWw== X-Gm-Message-State: AOJu0Yz/bHEd/Wt0EAB0DjJr8htjOl2/lpXf79+oilINA6BDDrR0xPp9 NdeYnvEhBhgS0iCmvYsi0iaSOzyS0Ug+EG7e4i+KsdJkc52ZMGoxCqwwwXrMxpSmhG4MuZI3WGs = X-Google-Smtp-Source: AGHT+IEaPaPCFxbC0o21UVSi90mpihWtEIlPclWuNLNabOkuBsS5xIggxNoUqqjCkw2bNPQr8B15Xw== X-Received: by 2002:a25:ef45:0:b0:db9:794b:5733 with SMTP id w5-20020a25ef45000000b00db9794b5733mr3315160ybm.19.1707257520516; Tue, 06 Feb 2024 14:12:00 -0800 (PST) Original-Received: from vader (68-252-220-225.lightspeed.tukrga.sbcglobal.net. [68.252.220.225]) by smtp.gmail.com with ESMTPSA id e3-20020a258743000000b00dc2324b3cddsm662468ybn.37.2024.02.06.14.11.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Feb 2024 14:11:59 -0800 (PST) In-Reply-To: (Stefan Monnier's message of "Mon, 05 Feb 2024 21:46:19 -0500") 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:279527 Archived-At: Stefan Monnier writes: >> There's one problem though. The autoloaded keybindings for >> `expand-jump-to-next-slot' and `expand-jump-to-previous-slot' won't work >> the first time they're called on an expanded skeleton, unless the user >> has previously loaded expand.el. > > Hmm... this suggests we should try and "merge" `expand-list/pos` and > `skeleton-positions`? My thinking was just to initialize `expand-list/pos/index` in skeleton.el, so that a skeleton-command could populate `expand-pos` with locations from `skeleton-positions` even before expand.el has loaded. I think `skeleton-positions` was intended as a building block for users (or package authors) to create jumping capability of their own. For example, an emacswiki article[1] proposes one way of doing this. I'd want to avoid renaming `skeleton-positions` or changing the value it receives, since that would probably break such configurations. [1] https://www.emacswiki.org/emacs/SkeletonMode#h5o-15 -- Best regards, Martin Marshall