From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Joseph Turner Newsgroups: gmane.emacs.devel Subject: Re: With electric-pair-mode, N prefix arg should insert N balanced pairs Date: Sat, 03 Aug 2024 00:07:00 -0700 Message-ID: <87plqqdqzv.fsf@breatheoutbreathe.in> References: <87y15edule.fsf@breatheoutbreathe.in> <86ikwiumza.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="21252"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Aug 03 11:05:06 2024 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 1saAhD-0005Ix-Kz for ged-emacs-devel@m.gmane-mx.org; Sat, 03 Aug 2024 11:05:04 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1saAgU-0008L5-CC; Sat, 03 Aug 2024 05:04:18 -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 1sa8rI-0006ja-3w for emacs-devel@gnu.org; Sat, 03 Aug 2024 03:07:20 -0400 Original-Received: from out-185.mta0.migadu.com ([2001:41d0:1004:224b::b9]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sa8r9-0000ci-Tr for emacs-devel@gnu.org; Sat, 03 Aug 2024 03:07:19 -0400 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=breatheoutbreathe.in; s=key1; t=1722668826; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Iemq93Bj9xoDmzIDmROrC+EDAAc3LNeAv6E6cxJIJOI=; b=ixceM95ge4RkdEsoFsqzP6mGK6i8jqM87hcXILJVUbqCVypfCtGg0+SuLp2mOYASfGBZoW syg9+wWlRkjpTeoEh1E4cWwdXMcrDRoJGQnWd82kuwz04m7jdOFXagtvk6P5hDsSLqT2XX It/R7em6eV39g4Sn6CfqyXbz9Ramdx8= In-Reply-To: <86ikwiumza.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 03 Aug 2024 09:41:45 +0300") X-Migadu-Flow: FLOW_OUT Received-SPF: pass client-ip=2001:41d0:1004:224b::b9; envelope-from=joseph@breatheoutbreathe.in; helo=out-185.mta0.migadu.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, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Sat, 03 Aug 2024 05:04:15 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:322299 Archived-At: Eli Zaretskii writes: >> From: Joseph Turner >> Date: Fri, 02 Aug 2024 22:49:17 -0700 [...] > Thanks, but why do you expect "(())" rather than "()()"? Electric > Pair mode works per inserted character, and doesn't know anything > about nesting. I noticed the unexpected behavior when attempting to surround some text with multiple braces in order to create Anki flashcards. More or less, I wanted to go from "foo" to "{{foo}}", and I thought perhaps that with the whole word selected, pressing "C-2 {" would DTRT. In general, I'm not sure whether "{}{}" or "{{}}"is more useful or expected, but I suspect both are better than "{{}". > In any case, this should have been submitted as a bug report, and go > to the bug tracker, not posted here. You're right. I'll repost on the bug tracker. Thank you! Joseph