GNU logs - #53661, boring messages


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#53661: 29.0.50; electric-pair-mode not respecting electric-pair-inhibit-predicate.
Resent-From: Ergus <spacibba@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Mon, 31 Jan 2022 15:08:01 +0000
Resent-Message-ID: <handler.53661.B.164364166423990 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: report 53661
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: 53661 <at> debbugs.gnu.org
X-Debbugs-Original-To: bug-gnu-emacs@HIDDEN
Received: via spool by submit <at> debbugs.gnu.org id=B.164364166423990
          (code B ref -1); Mon, 31 Jan 2022 15:08:01 +0000
Received: (at submit) by debbugs.gnu.org; 31 Jan 2022 15:07:44 +0000
Received: from localhost ([127.0.0.1]:40232 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nEYHQ-0006Er-4w
	for submit <at> debbugs.gnu.org; Mon, 31 Jan 2022 10:07:44 -0500
Received: from lists.gnu.org ([209.51.188.17]:37998)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <spacibba@HIDDEN>) id 1nEYHO-0006Ek-K5
 for submit <at> debbugs.gnu.org; Mon, 31 Jan 2022 10:07:43 -0500
Received: from eggs.gnu.org ([209.51.188.92]:38516)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <spacibba@HIDDEN>) id 1nEYHH-0002C5-K4
 for bug-gnu-emacs@HIDDEN; Mon, 31 Jan 2022 10:07:40 -0500
Received: from sonic311-14.consmr.mail.bf2.yahoo.com ([74.6.131.124]:37042)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <spacibba@HIDDEN>) id 1nEYHD-0002La-7O
 for bug-gnu-emacs@HIDDEN; Mon, 31 Jan 2022 10:07:34 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048;
 t=1643641645; bh=1y6nZVLQSQi6+9a14PCqR9YRvhcG2LzL62jpZ4mZNf4=;
 h=From:To:Cc:Subject:Date:References:From:Subject:Reply-To;
 b=EsgTOYLOEjyfgLgEPL1g1LhAf3wJqCMzVpepZBgjhqFiKr3VxZsfMJMWi+gdQRH2L9jbQ+AubQsY1160jev1Qf1Z3gC2EkroWJzwlOiagwqCPqTM0F0L5MvDRcGgE2FoodysLC0shNhqILLTH1LFNZH79wavVjNbkNq97fKBmZiqYJ3D57zl2V6PCpRMZknb8ZHOhWjM1XejiL8obpT+8AAHKh07exwC3HZz4KyIDhI1zdxirqE7aUPKjzYg4422E+ZIZ4rXZtJ/G3NMb1zzPHF0LV0Vzxrk0pjjk7rijKBj2INtHVk/QsQE3w4tm4kXs78zj1g1oPfhfX0DsC0fpg==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1643641645; bh=2a27nCwK5DeVSDCOKv38NfUgKcxAVPPFup9JmGM5NA4=;
 h=X-Sonic-MF:From:To:Subject:Date:From:Subject;
 b=gK65rFxyyqO3nsnfIAuSvQLwgpL1Og/z42NB8CZ/M5qs0+iRukIJJO+OepWEEGVem/ioi2zP9opPboWiqSUxXTiZQC9ScYJOJCX8q+EY7RoG4DjA4Oxel4GRp3XiETa/KNZTaShRPUr3sbMr7wO+eeGpNKw9xoPAPfHPJceQXBdfxRO/KMpJy/9rLX7zNbYVs9rPDHy/wBYIkRRtyHt4vCl2Catam+C93Na3jHBJE9564sBb5dzwT1ImT61+VLr9lWTOWsvNglL1uRckxpKmxkyPFXF9n8GDwOf0q5Fxlmm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pn4YNN15K4kyYc_yPKQMr.FOy0VyfxIersG4iJj1DlQ9t0q_lzLP4
 YfggAISUyopTXvHBv8ipikzMhI.eEBLSeDlwrtMrY39BVIWimDrnQGGwYL24aXLf.9krBLAATsQF
 Is86Q94Ysc2WVZ1f.VkkKLpTGsrx.gi_tIljGoBb3AGqLR8q6q0ud9TAOK9BfWus.nMOV5P2CAwV
 idGJr
X-Sonic-MF: <spacibba@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic311.consmr.mail.bf2.yahoo.com with HTTP; Mon, 31 Jan 2022 15:07:25 +0000
Received: by kubenode503.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP
 Server) with ESMTPA ID 556449a525c3bc450d495e3508e8aea9; 
 Mon, 31 Jan 2022 15:07:22 +0000 (UTC)
From: Ergus <spacibba@HIDDEN>
Date: Mon, 31 Jan 2022 16:06:39 +0100
Message-ID: <87fsp4eygw.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
References: <87fsp4eygw.fsf.ref@HIDDEN>
X-Mailer: WebService/1.1.19615
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol
Content-Length: 8614
Received-SPF: pass client-ip=74.6.131.124; envelope-from=spacibba@HIDDEN;
 helo=sonic311-14.consmr.mail.bf2.yahoo.com
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.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,
 RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.3 (-)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)


Hi:

When adding new pairs to `electric-pair-pairs' the
`electric-pair-inhibit-predicate' variable is not respected.

Looking at the elect-pair file it seems to be related with:
`electric-pair-post-self-insert-function' that hard-coded the condition
to call `electric-pair-inhibit-predicate' with:

(memq syntax '(?\( ?\" ?\$))

So, for other pairs, the function electric-pair-inhibit-predicate is
never called.

The fix only for this seems trivial, but there are hard-coded conditions
like this in many places, so maybe a more "complete" fix may be
desirable.

Best


I faced this issue trying to implement a workaround to add some pairs
that are only electrically inserted when `use-region-p' (Ex: <> or '').


In GNU Emacs 29.0.50 (build 50, x86_64-pc-linux-gnu, GTK+ Version 3.24.31, cairo version 1.17.4)
 of 2022-01-31 built on Ergus
Repository revision: 9a56b4e6864c4e0815bb67805cfa67910ab3eeb5
Repository branch: master
System Description: Arch Linux

Configured using:
 'configure --prefix=/home/ergo/.local/ --with-mailutils --with-json
 --with-x-toolkit=gtk3 --with-xft --with-wide-int --with-modules
 --with-cairo --with-harfbuzz --with-native-compilation --with-pgtk'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER
PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS
WEBP XIM GTK3 ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: ELisp/d

Minor modes in effect:
  windmove-mode: t
  global-auto-revert-mode: t
  xclip-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  flyspell-mode: t
  company-mode: t
  flycheck-mode: t
  diff-hl-margin-local-mode: t
  diff-hl-margin-mode: t
  diff-hl-mode: t
  counsel-mode: t
  ivy-mode: t
  composable-mark-mode: t
  composable-mode: t
  repeat-mode: t
  xterm-mouse-mode: t
  minibuffer-depth-indicate-mode: t
  winner-mode: t
  show-smartparens-global-mode: t
  show-smartparens-mode: t
  smartparens-strict-mode: t
  smartparens-mode: t
  save-place-mode: t
  which-key-mode: t
  override-global-mode: t
  delete-selection-mode: t
  savehist-mode: t
  global-display-fill-column-indicator-mode: t
  display-fill-column-indicator-mode: t
  global-display-line-numbers-mode: t
  display-line-numbers-mode: t
  eldoc-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  context-menu-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  size-indication-mode: t
  column-number-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t

Load-path shadows:
~/gits/emacs_clones/composable/composable-mark hides /home/ergo/.config/emacs/elpa/composable-20201024.1458/composable-mark
~/gits/emacs_clones/composable/composable hides /home/ergo/.config/emacs/elpa/composable-20201024.1458/composable
/home/ergo/.config/emacs/elpa/transient-20220130.1941/transient hides /home/ergo/.local/share/emacs/29.0.50/lisp/transient
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-jump hides /usr/share/emacs/site-lisp/notmuch-jump
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-hello hides /usr/share/emacs/site-lisp/notmuch-hello
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-query hides /usr/share/emacs/site-lisp/notmuch-query
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-show hides /usr/share/emacs/site-lisp/notmuch-show
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-parser hides /usr/share/emacs/site-lisp/notmuch-parser
/home/ergo/.config/emacs/elpa/cmake-mode-20210104.1831/cmake-mode hides /usr/share/emacs/site-lisp/cmake-mode
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-wash hides /usr/share/emacs/site-lisp/notmuch-wash
/home/ergo/.config/emacs/elpa/protobuf-mode-20211013.1726/protobuf-mode hides /usr/share/emacs/site-lisp/protobuf-mode
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-crypto hides /usr/share/emacs/site-lisp/notmuch-crypto
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-tree hides /usr/share/emacs/site-lisp/notmuch-tree
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/coolj hides /usr/share/emacs/site-lisp/coolj
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-lib hides /usr/share/emacs/site-lisp/notmuch-lib
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-compat hides /usr/share/emacs/site-lisp/notmuch-compat
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-company hides /usr/share/emacs/site-lisp/notmuch-company
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-draft hides /usr/share/emacs/site-lisp/notmuch-draft
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-tag hides /usr/share/emacs/site-lisp/notmuch-tag
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-message hides /usr/share/emacs/site-lisp/notmuch-message
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-mua hides /usr/share/emacs/site-lisp/notmuch-mua
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-address hides /usr/share/emacs/site-lisp/notmuch-address
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-print hides /usr/share/emacs/site-lisp/notmuch-print
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch hides /usr/share/emacs/site-lisp/notmuch
/home/ergo/.config/emacs/elpa/notmuch-20220126.1122/notmuch-maildir-fcc hides /usr/share/emacs/site-lisp/notmuch-maildir-fcc

Features:
(shadow sort mail-extr emacsbug message yank-media rmc puny rfc822 mml
mml-sec epa derived epg rfc6068 epg-config gnus-util mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils windmove
time-date amx s autorevert filenotify xclip yasnippet-snippets yasnippet
help-fns radix-tree cl-print debug backtrace flyspell-correct-ivy
flyspell-correct flyspell ispell company-semantic company-template
company-capf company-elisp company flycheck find-func pcase
diff-hl-margin diff-hl-dired diff-hl log-view pcvs-util vc-dir ewoc vc
cape counsel xdg xref project dired dired-loaddefs compile
text-property-search comint ansi-color swiper ivy-avy avy ivy flx
ivy-faces ivy-overlay colir vc-git diff-mode vc-dispatcher term/tmux
term/xterm xterm init composable composable-mark powerline comp
comp-cstr warnings powerline-separators color powerline-themes repeat
xt-mouse edmacro kmacro mb-depth simple-16-theme winner ring elec-pair
smartparens-config smartparens-text smartparens advice thingatpt dash
saveplace diminish which-key cl-extra help-mode use-package
use-package-ensure use-package-delight use-package-diminish
use-package-bind-key bind-key use-package-core disp-table delsel
savehist easy-mmode display-fill-column-indicator display-line-numbers
ede/auto eieio-base tex-site slime-autoloads rx info package browse-url
url url-proxy url-privacy url-expand url-methods url-history url-cookie
url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq
eieio eieio-core cl-macs eieio-loaddefs password-cache json map url-vars
seq gv subr-x byte-opt bytecomp byte-compile cconv early-init profiler
cl-loaddefs cl-lib iso-transl tooltip eldoc paren electric uniquify
ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win
pgtk-win term/common-win tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode lisp-mode prog-mode register
page tab-bar menu-bar rfn-eshadow isearch easymenu timer select
scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors
frame minibuffer cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite emoji-zwj charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button
loaddefs faces cus-face macroexp files window text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget keymap
hashtable-print-readable backquote threads dbusbind inotify
dynamic-setting system-font-setting font-render-setting cairo
move-toolbar gtk x-toolkit pgtk lcms2 multi-tty make-network-process
native-compile emacs)

Memory information:
((conses 16 410033 140294)
 (symbols 48 23414 1)
 (strings 32 87030 22121)
 (string-bytes 1 3013452)
 (vectors 16 59969)
 (vector-slots 8 1599695 599854)
 (floats 8 212 1163)
 (intervals 56 7255 3355)
 (buffers 992 17))




Message sent:


Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
Content-Type: text/plain; charset=utf-8
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Ergus <spacibba@HIDDEN>
Subject: bug#53661: Acknowledgement (29.0.50; electric-pair-mode not
 respecting electric-pair-inhibit-predicate.)
Message-ID: <handler.53661.B.164364166423990.ack <at> debbugs.gnu.org>
References: <87fsp4eygw.fsf@HIDDEN>
X-Gnu-PR-Message: ack 53661
X-Gnu-PR-Package: emacs
Reply-To: 53661 <at> debbugs.gnu.org
Date: Mon, 31 Jan 2022 15:08:01 +0000

Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
 bug-gnu-emacs@HIDDEN

If you wish to submit further information on this problem, please
send it to 53661 <at> debbugs.gnu.org.

Please do not send mail to help-debbugs@HIDDEN unless you wish
to report a problem with the Bug-tracking system.

--=20
53661: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D53661
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#53661: 29.0.50; electric-pair-mode not respecting electric-pair-inhibit-predicate.
Resent-From: Eli Zaretskii <eliz@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Mon, 31 Jan 2022 16:43:01 +0000
Resent-Message-ID: <handler.53661.B53661.164364733028467 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 53661
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Ergus <spacibba@HIDDEN>
Cc: 53661 <at> debbugs.gnu.org
Received: via spool by 53661-submit <at> debbugs.gnu.org id=B53661.164364733028467
          (code B ref 53661); Mon, 31 Jan 2022 16:43:01 +0000
Received: (at 53661) by debbugs.gnu.org; 31 Jan 2022 16:42:10 +0000
Received: from localhost ([127.0.0.1]:40464 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nEZko-0007P5-CY
	for submit <at> debbugs.gnu.org; Mon, 31 Jan 2022 11:42:10 -0500
Received: from eggs.gnu.org ([209.51.188.92]:36260)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1nEZkn-0007Or-E8
 for 53661 <at> debbugs.gnu.org; Mon, 31 Jan 2022 11:42:09 -0500
Received: from [2001:470:142:3::e] (port=50886 helo=fencepost.gnu.org)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nEZkh-00039o-Uo; Mon, 31 Jan 2022 11:42:03 -0500
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=QD+UpRPXr2w2LI+p4JrVrgt+JLaNaVgQt+i/1YSbvzc=; b=XQ74teRlA/1y
 WkYIQ4FsCLcqEbf5QpR4njOEYZYocGP+9xHoUBtE21+TDR8NA0h3fGf4gfaLqTst8Iq+q6XNo4n+W
 TMpU9t2gAUHRAhbUBFULg4xSqtWReSJx3dZEvD+uBuBBvAOjbThbyoz1lGadtN338mW4GJbSzGPcM
 Nz7Zth9PAKQYu5ql727JsdZUoZXHYM9YZKGuplr9Rg5IPVUuyKvom7horf6FUEnMOggXUyL83ji0o
 7AfHqcRIF3yshu9stfJh/gGt19NXT9iH1tqdYA5NXhBACFweN9VqzbyPghvbuIx4hnOn3l26Q/V/M
 sYcR5AE0YoK6sdHF5F5/yw==;
Received: from [87.69.77.57] (port=1324 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1nEZkh-00015g-E6; Mon, 31 Jan 2022 11:42:03 -0500
Date: Mon, 31 Jan 2022 18:41:59 +0200
Message-Id: <83iltz97s8.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
In-Reply-To: <87fsp4eygw.fsf@HIDDEN> (bug-gnu-emacs@HIDDEN)
References: <87fsp4eygw.fsf.ref@HIDDEN> <87fsp4eygw.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> Date: Mon, 31 Jan 2022 16:06:39 +0100
> From:  Ergus via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
> 
> When adding new pairs to `electric-pair-pairs' the
> `electric-pair-inhibit-predicate' variable is not respected.
> 
> Looking at the elect-pair file it seems to be related with:
> `electric-pair-post-self-insert-function' that hard-coded the condition
> to call `electric-pair-inhibit-predicate' with:
> 
> (memq syntax '(?\( ?\" ?\$))
> 
> So, for other pairs, the function electric-pair-inhibit-predicate is
> never called.

The above condition looks at the _syntax_ of a character, not at the
character itself.  So what do you find "hard-coded" there,and what
kind of pairs of characters did you want to add that don't have one of
those syntaxes?




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#53661: 29.0.50; electric-pair-mode not respecting electric-pair-inhibit-predicate.
Resent-From: Ergus <spacibba@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Mon, 31 Jan 2022 17:31:02 +0000
Resent-Message-ID: <handler.53661.B53661.164365022329081 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 53661
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Eli Zaretskii <eliz@HIDDEN>
Cc: 53661 <at> debbugs.gnu.org
Received: via spool by 53661-submit <at> debbugs.gnu.org id=B53661.164365022329081
          (code B ref 53661); Mon, 31 Jan 2022 17:31:02 +0000
Received: (at 53661) by debbugs.gnu.org; 31 Jan 2022 17:30:23 +0000
Received: from localhost ([127.0.0.1]:40637 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1nEaVS-0007Ya-SO
	for submit <at> debbugs.gnu.org; Mon, 31 Jan 2022 12:30:23 -0500
Received: from sonic301-3.consmr.mail.bf2.yahoo.com ([74.6.129.42]:43865)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <spacibba@HIDDEN>) id 1nEaVQ-0007QZ-Mv
 for 53661 <at> debbugs.gnu.org; Mon, 31 Jan 2022 12:30:21 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048;
 t=1643650213; bh=1kcR1ZolGagsaAznVDpWSh/CBBQbvqwXpSA59RIqEwQ=;
 h=Date:From:To:Cc:Subject:References:In-Reply-To:From:Subject:Reply-To;
 b=tiiR7SljKWkjvCw7TSHu5gEldY44cWnRYAzbTrG9L2f4wdjzj7QepPXinQjdvv8mlXhmywVQawIGqvDpWKTUFRZx9vkUXMc6f0yViBjimfDtAgSY/HMGTk5BS/Eol6f9DtqIRG8cJC3g73KPRl1qfMwHjzgWHUfrTJwvEvs/yZDGURkUMOJ/D4QFczANCmcbj2k02EA6ipE9i1Fac0RDXLEZgNDGJDJe+eIFZpB588Y/xgqSAvNZaRVa2KFq0hjM5arP1naNuBut5eoYji4oKwYGDsnlEKB3rFKE9//jK/F/wkcQBkQGIoNHurcja1zklMdPt1JaeJnKGGTbi28H6Q==
X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048;
 t=1643650213; bh=otbE65iNkG5NtkcXNaOa9RfHBMg5OzWBbE+39kaZu5e=;
 h=X-Sonic-MF:Date:From:To:Subject:From:Subject;
 b=tkG++oxxWfoKyh5lp8MI8xCprVZo3H5wljypSTfXVGewbLMeuYc/4DFJpy/w0EpqGXHiaU3scpUjll+Jgf+ircbnVne42oFpQcmAfpCWoC4119v4QyquSoWJCmFhx82WCw+BYZXSMVR8Vb+VyGkdHN3SAV8jHehnf8NhJOU++ZCLsV/97NXkkmDIY8W+XivVTgeV2DlEf6ns1lSZg8W+1MOIA6zC2/3hthbahgh073rt7ZmwMyfnnGDd9kd0OoBwm1LNpO2iIJaRPiSQLZKoTUL/f80ltqmrsXFIxMpskLB4IQV+zdRlPrn0mM/BVQIsCDpmphXgK+RDuAQUhoCrbw==
X-YMail-OSG: cFVPGA0VM1np58YtKSC0hO0SMicW2EAV8yZkWYCJhAsbFRscfccHWRGF8aEH.xU
 GvnsO93el7fjOwPboGfX4zkYGV4NNNg98FS_I09M7yzq4lioBaZuZXIp_wsn34uaoYrlo._v34ZE
 Wk7_MjEJJN6y.lPPVzqLC4tegeKmEtkyb5a8wThCN8TI5DTqngB1LPaIROih96a9da_TBqvCP_yE
 nJFVH7W_4Zlo_dkLSkdEqGBqPRp_UTE_rt0XjdSSwS4VjJA2lWnptbVjYn54aZLstqhhW7RX2Iny
 u14giASkdF4KE9AnV7SBZ3vePOZCqMFn9JByxmpGP7sIConkVzFj6Brzh14MpDh8YZKUVCjHitSM
 Du1gtXqzn9VBJgWhNuSXgNUUG9baEopFeYlkQEjhtwDAsCamvEYdmew_YVIqgdG3rffRx6oc39kg
 j614AM6pmMDU82XBelLc6HHZNz720IZP5cluSLv1KAwpEM.NP0UnuQTJce_VZjOo07YC1KyTZnwU
 cU33cqmTDRtK4BjUDRtvIDZfTqlxgN4Vj5m_YTw_n8vv_HKwWwPt5qi_HCUqk.h6X_ruiCbhxYSV
 Snm8hN9TXi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S
 CZuIzbo5aPQJb2IaEt1Uhe52t_QDWKl6AUnhvG7NKF1SEtiN_d_DhBdnA5l84am5yoAKR2U4RMRO
 0FEO7K7o66eqzs6WcqmngvEPPsh9yQtkAVQGz6OVb2pnM4R9SDFdk0kWKE9MjZg_ae3YrD9N1Dpw
 fNYRXzJgs_9nH6t_hvZ8RsvCfod4iKqg4YNyA8Q.pOYfTLpI_PwJ4pQoyggZOKnp12D2drvb6yEd
 x_dCn6_dtC5wEnB.uWjlxPPrbIpR89EhM2hw3oUGGMjKLgK9VtApFrWpQFsry0n4W3jJ1oP7z8Jq
 feE4ggEpsATvanY_xmm.19aHFZ6fBFm7ydV6dn_99e9zmIxBI1VVhvaSqL7qXvP9at_PfJsk548O
 TspvBbX4M5s1Agv0rlT1hBjz5MRMmVaISOnsT7kXVAOb6a3pTqreklGUWw0mmuoj8Ycg.92ZDzOW
 Etbr3VKsh8c1WHC9zQoLNxD_q7hui4x72FgNBCXVz1.dXYg6NbD0TIGT8ArsXO.5FJRBFI6_IWuf
 jf5daaeaL1BAn.v9DjU8s7mx4pNHw8xCG84IeV6KeEJCv4p_a4z0HiTbeUF4SaE7pMa9dx0Me20o
 fEfekB29mKnqq48Q0k00-
X-Sonic-MF: <spacibba@HIDDEN>
Received: from sonic.gate.mail.ne1.yahoo.com by
 sonic301.consmr.mail.bf2.yahoo.com with HTTP; Mon, 31 Jan 2022 17:30:13 +0000
Received: by kubenode503.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP
 Server) with ESMTPA ID b26f4ba8d947066bcd1d00d511d6bdac; 
 Mon, 31 Jan 2022 17:30:11 +0000 (UTC)
Date: Mon, 31 Jan 2022 18:29:31 +0100
From: Ergus <spacibba@HIDDEN>
Message-ID: <20220131172931.fwqtax34h6a5v4o4@Ergus>
References: <87fsp4eygw.fsf.ref@HIDDEN> <87fsp4eygw.fsf@HIDDEN>
 <83iltz97s8.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Disposition: inline
In-Reply-To: <83iltz97s8.fsf@HIDDEN>
X-Mailer: WebService/1.1.19615
 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol
Content-Length: 1427
X-Spam-Score: 0.0 (/)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

On Mon, Jan 31, 2022 at 06:41:59PM +0200, Eli Zaretskii wrote:
>> Date: Mon, 31 Jan 2022 16:06:39 +0100
>> From:  Ergus via "Bug reports for GNU Emacs,
>>  the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
>>
>> When adding new pairs to `electric-pair-pairs' the
>> `electric-pair-inhibit-predicate' variable is not respected.
>>
>> Looking at the elect-pair file it seems to be related with:
>> `electric-pair-post-self-insert-function' that hard-coded the condition
>> to call `electric-pair-inhibit-predicate' with:
>>
>> (memq syntax '(?\( ?\" ?\$))
>>
>> So, for other pairs, the function electric-pair-inhibit-predicate is
>> never called.
>
>The above condition looks at the _syntax_ of a character, not at the
>character itself.  So what do you find "hard-coded" there,and what
>kind of pairs of characters did you want to add that don't have one of
>those syntaxes?

Hi Eli:

I wanted to add "<>" so I added to my init:

(add-to-list 'electric-pair-pairs '(?< . ?>))

But I wanted to restrict the electric-insertion only to when the region
was active; else using `<` to compare may be wrong; so I thought that
implementing my own `electric-pair-inhibit-predicate' in a simple way
like more or less:

(if (and (eq char ?<) (not (use-region-p)))
     t
     (electric-pair-default-inhibit))

could make the trick, but this doesn't work as I thought. I don't know
if there is a better way to go around this. 





Last modified: Mon, 31 Jan 2022 17:45:01 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.