From unknown Fri Jun 13 11:49:55 2025 X-Loop: help-debbugs@gnu.org Subject: bug#34596: Typo in regex-opt doc string Resent-From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 20 Feb 2019 22:12:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 34596 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 34596@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15507006887250 (code B ref -1); Wed, 20 Feb 2019 22:12:01 +0000 Received: (at submit) by debbugs.gnu.org; 20 Feb 2019 22:11:28 +0000 Received: from localhost ([127.0.0.1]:58708 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gwa5O-0001sq-SF for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:27 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gwa5N-0001sd-9Z for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:26 -0500 Received: from lists.gnu.org ([209.51.188.17]:57310) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gwa5G-0003Ej-Ry for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:20 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57950) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gwa5G-0005b5-1K for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:18 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.1 required=5.0 tests=BAYES_50,RCVD_IN_DNSWL_LOW, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gwa5C-00039G-Bk for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:18 -0500 Received: from mail179c50.megamailservers.eu ([91.136.10.189]:58840 helo=mail18c50.megamailservers.eu) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gwa50-00032S-AP for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:04 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1550700654; bh=xGkohUyPOK/H7i2dv9bawNjkPWaRxKz8iKyCXrtc1Vo=; h=From:Subject:Date:To:From; b=lMoTR+UEJSgUTrDfU5PtJW1g4ksSaEpUnnhrg+439q/IOVs8A3Bca750vbBwAaQP/ USS8goWFEwHVY2AElXCgjGJlWY94NFgDq7CJ8M7l/QE/BRlHdcXi1KcHvKX9rQOS4/ Cm5h9osKMbZieg+ui377UZnkRrKorxVBkS+2DAHQ= Feedback-ID: mattiase@acm.or Received: from [192.168.1.65] (c-e636e253.032-75-73746f71.bbcust.telenor.se [83.226.54.230]) (authenticated bits=0) by mail18c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id x1KMAqUE026315 for ; Wed, 20 Feb 2019 22:10:54 +0000 From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Message-Id: <48ED042C-46BD-4233-9423-92EADB8494B0@acm.org> Date: Wed, 20 Feb 2019 23:10:52 +0100 X-Mailer: Apple Mail (2.3445.102.3) X-CTCH-RefID: str=0001.0A0B0214.5C6DD06E.001F, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=KOR08mNo c=1 sm=1 tr=0 a=M+GU/qJco4WXjv8D6jB2IA==:117 a=M+GU/qJco4WXjv8D6jB2IA==:17 a=kj9zAlcOel0A:10 a=lnWWFSKvlA1xSWXuVVsA:9 a=CjuIK1q_8ugA:10 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 91.136.10.189 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: 1.0 (+) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) The example code in the regexp-opt doc string doesn't actually work = because of a typo: (defun simplified-regexp-opt (strings &optional paren) (let ((parens (cond ((stringp paren) (cons paren "\\)")) ((eq paren 'words) '("\\<\\(" . "\\)\\>")) ((eq paren 'symbols) '("\\_<\\(" . "\\)\\_>")) ((null paren) '("\\(?:" . "\\)")) (t '("\\(" . "\\)"))))) (concat (car paren) (mapconcat 'regexp-quote strings "\\|") (cdr paren)))) `paren' should be `parens' in the last three lines. From unknown Fri Jun 13 11:49:55 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Subject: bug#34596: closed (Re: bug#34596: Typo in regex-opt doc string) Message-ID: References: <83d0nkfdh0.fsf@gnu.org> <48ED042C-46BD-4233-9423-92EADB8494B0@acm.org> X-Gnu-PR-Message: they-closed 34596 X-Gnu-PR-Package: emacs Reply-To: 34596@debbugs.gnu.org Date: Fri, 22 Feb 2019 08:14:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1550823242-11170-1" This is a multi-part message in MIME format... ------------=_1550823242-11170-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #34596: Typo in regex-opt doc string which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 34596@debbugs.gnu.org. --=20 34596: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D34596 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1550823242-11170-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 34596-done) by debbugs.gnu.org; 22 Feb 2019 08:13:11 +0000 Received: from localhost ([127.0.0.1]:47567 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gx5xG-0002sw-5O for submit@debbugs.gnu.org; Fri, 22 Feb 2019 03:13:11 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57591) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gx5xE-0002sk-JM for 34596-done@debbugs.gnu.org; Fri, 22 Feb 2019 03:13:08 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40811) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gx5x9-0007iK-BD; Fri, 22 Feb 2019 03:13:03 -0500 Received: from [176.228.60.248] (port=3495 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1gx5x4-0008GY-VR; Fri, 22 Feb 2019 03:13:01 -0500 Date: Fri, 22 Feb 2019 10:12:59 +0200 Message-Id: <83d0nkfdh0.fsf@gnu.org> From: Eli Zaretskii To: Mattias =?utf-8?Q?Engdeg=C3=A5rd?= In-reply-to: <48ED042C-46BD-4233-9423-92EADB8494B0@acm.org> (message from Mattias =?utf-8?Q?Engdeg=C3=A5rd?= on Wed, 20 Feb 2019 23:10:52 +0100) Subject: Re: bug#34596: Typo in regex-opt doc string References: <48ED042C-46BD-4233-9423-92EADB8494B0@acm.org> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 34596-done Cc: 34596-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > From: Mattias EngdegÄrd > Date: Wed, 20 Feb 2019 23:10:52 +0100 > > (defun simplified-regexp-opt (strings &optional paren) > (let ((parens > (cond ((stringp paren) (cons paren "\\)")) > ((eq paren 'words) '("\\<\\(" . "\\)\\>")) > ((eq paren 'symbols) '("\\_<\\(" . "\\)\\_>")) > ((null paren) '("\\(?:" . "\\)")) > (t '("\\(" . "\\)"))))) > (concat (car paren) > (mapconcat 'regexp-quote strings "\\|") > (cdr paren)))) > > `paren' should be `parens' in the last three lines. Thanks, fixed. ------------=_1550823242-11170-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 20 Feb 2019 22:11:28 +0000 Received: from localhost ([127.0.0.1]:58708 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gwa5O-0001sq-SF for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:27 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gwa5N-0001sd-9Z for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:26 -0500 Received: from lists.gnu.org ([209.51.188.17]:57310) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gwa5G-0003Ej-Ry for submit@debbugs.gnu.org; Wed, 20 Feb 2019 17:11:20 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57950) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gwa5G-0005b5-1K for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:18 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.1 required=5.0 tests=BAYES_50,RCVD_IN_DNSWL_LOW, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gwa5C-00039G-Bk for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:18 -0500 Received: from mail179c50.megamailservers.eu ([91.136.10.189]:58840 helo=mail18c50.megamailservers.eu) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gwa50-00032S-AP for bug-gnu-emacs@gnu.org; Wed, 20 Feb 2019 17:11:04 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1550700654; bh=xGkohUyPOK/H7i2dv9bawNjkPWaRxKz8iKyCXrtc1Vo=; h=From:Subject:Date:To:From; b=lMoTR+UEJSgUTrDfU5PtJW1g4ksSaEpUnnhrg+439q/IOVs8A3Bca750vbBwAaQP/ USS8goWFEwHVY2AElXCgjGJlWY94NFgDq7CJ8M7l/QE/BRlHdcXi1KcHvKX9rQOS4/ Cm5h9osKMbZieg+ui377UZnkRrKorxVBkS+2DAHQ= Feedback-ID: mattiase@acm.or Received: from [192.168.1.65] (c-e636e253.032-75-73746f71.bbcust.telenor.se [83.226.54.230]) (authenticated bits=0) by mail18c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id x1KMAqUE026315 for ; Wed, 20 Feb 2019 22:10:54 +0000 From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Subject: Typo in regex-opt doc string Message-Id: <48ED042C-46BD-4233-9423-92EADB8494B0@acm.org> Date: Wed, 20 Feb 2019 23:10:52 +0100 To: bug-gnu-emacs@gnu.org X-Mailer: Apple Mail (2.3445.102.3) X-CTCH-RefID: str=0001.0A0B0214.5C6DD06E.001F, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Rules: X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=KOR08mNo c=1 sm=1 tr=0 a=M+GU/qJco4WXjv8D6jB2IA==:117 a=M+GU/qJco4WXjv8D6jB2IA==:17 a=kj9zAlcOel0A:10 a=lnWWFSKvlA1xSWXuVVsA:9 a=CjuIK1q_8ugA:10 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 91.136.10.189 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) The example code in the regexp-opt doc string doesn't actually work = because of a typo: (defun simplified-regexp-opt (strings &optional paren) (let ((parens (cond ((stringp paren) (cons paren "\\)")) ((eq paren 'words) '("\\<\\(" . "\\)\\>")) ((eq paren 'symbols) '("\\_<\\(" . "\\)\\_>")) ((null paren) '("\\(?:" . "\\)")) (t '("\\(" . "\\)"))))) (concat (car paren) (mapconcat 'regexp-quote strings "\\|") (cdr paren)))) `paren' should be `parens' in the last three lines. ------------=_1550823242-11170-1--