From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: Please add comments to isearch.el Date: Sun, 13 Dec 2015 01:27:45 +0200 Organization: LINKOV.NET Message-ID: <874mfntfgq.fsf@mail.linkov.net> References: <83fuzoojcn.fsf@gnu.org> <83poyd8kta.fsf@gnu.org> <20151211121617.GA3351@acm.fritz.box> <83y4d16txk.fsf@gnu.org> <83lh916jpp.fsf@gnu.org> <871tasbnhh.fsf@mail.linkov.net> <83d1uc6sdq.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1449964122 8225 80.91.229.3 (12 Dec 2015 23:48:42 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 12 Dec 2015 23:48:42 +0000 (UTC) Cc: acm@muc.de, bruce.connor.am@gmail.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Dec 13 00:48:35 2015 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1a7ttx-0000s9-PD for ged-emacs-devel@m.gmane.org; Sun, 13 Dec 2015 00:48:33 +0100 Original-Received: from localhost ([::1]:53404 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7ttx-0000DO-9G for ged-emacs-devel@m.gmane.org; Sat, 12 Dec 2015 18:48:33 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56125) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7ttf-0000DB-55 for emacs-devel@gnu.org; Sat, 12 Dec 2015 18:48:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a7tte-0007Dj-7r for emacs-devel@gnu.org; Sat, 12 Dec 2015 18:48:15 -0500 Original-Received: from sub3.mail.dreamhost.com ([69.163.253.7]:44537 helo=homiemail-a21.g.dreamhost.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a7ttb-0007D1-4R; Sat, 12 Dec 2015 18:48:11 -0500 Original-Received: from homiemail-a21.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a21.g.dreamhost.com (Postfix) with ESMTP id 717E1300064; Sat, 12 Dec 2015 15:48:10 -0800 (PST) Original-Received: from localhost.linkov.net (m83-180-31-224.cust.tele2.ee [83.180.31.224]) (Authenticated sender: jurta@jurta.org) by homiemail-a21.g.dreamhost.com (Postfix) with ESMTPA id 0266B300059; Sat, 12 Dec 2015 15:48:08 -0800 (PST) In-Reply-To: <83d1uc6sdq.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 12 Dec 2015 09:25:05 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (x86_64-pc-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 69.163.253.7 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:196187 Archived-At: > Hey, I didn't suggest refactoring to begin with. I suggested to add > commentary to explain how things work there. The example you give is > just another confirmation of my observation that the code in > isearch.el has long ago crossed the line of being unmaintainable, and > I think we should fix that ASAP. > > Thanks. I completely agree, and as a first step in this direction I propose to fix the terminology used in isearch that should help to better understand the code in isearch.el. 1. Rename =E2=80=98lax=E2=80=99 to =E2=80=98lax-boundary=E2=80=99 to dist= inguish between lax at the word/symbol boundary and lax-whitespace to avoid confusion, so rename the arg =E2=80=98lax=E2=80=99 to =E2=80=98lax-boundary=E2=80=99 in all reg= exp-producing functions, isearch--lax-regexp-function-p to isearch--lax-boundary-regexp-function-p, etc. 2. Try to find a better common naming scheme used for the regexp-producing functions word-search-regexp, isearch-symbol-regexp, character-fold-to-regexp. 3. Use well established terminology that shortens the prefixes of character-related functions to just char- to use char-fold. =E2=80=98C-h f char TAB=E2=80=99 or =E2=80=98C-h v char TAB=E2=80=99 s= hows the standard Emacs naming convention. 4. Use the upper-case standard name =E2=80=9CUnicode=E2=80=9D in the docu= mentation.