From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tim Johnson Newsgroups: gmane.emacs.help Subject: Info [was Re: re-search beginning of line or whitespace] Date: Fri, 4 Nov 2005 07:38:28 -0900 Message-ID: <20051104163828.GG1791@johnsons-web.com> References: <20051101152338.3161.qmail@mail.jfudy.com> <20051102023946.GB1791@johnsons-web.com> <20051102032355.GA10016@SDF.LONESTAR.ORG> <20051102171914.GC1791@johnsons-web.com> <20051103203316.GA29396@SDF.LONESTAR.ORG> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1131124887 2455 80.91.229.2 (4 Nov 2005 17:21:27 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 4 Nov 2005 17:21:27 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Nov 04 18:21:16 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1EY5Cs-00011h-Kr for geh-help-gnu-emacs@m.gmane.org; Fri, 04 Nov 2005 18:18:27 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EY5Cs-0006v2-1d for geh-help-gnu-emacs@m.gmane.org; Fri, 04 Nov 2005 12:18:26 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EY5Ar-00068m-Ro for help-gnu-emacs@gnu.org; Fri, 04 Nov 2005 12:16:22 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EY5Ak-00064E-NL for help-gnu-emacs@gnu.org; Fri, 04 Nov 2005 12:16:17 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EY5Aj-00063W-So for help-gnu-emacs@gnu.org; Fri, 04 Nov 2005 12:16:14 -0500 Original-Received: from [208.218.214.44] (helo=ns3.cniweb.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1EY5Aj-0006XO-JK for help-gnu-emacs@gnu.org; Fri, 04 Nov 2005 12:16:13 -0500 Original-Received: from linus.johnson.com (rdbck-static-445.palmer.mtaonline.net [64.4.232.191]) by ns3.cniweb.net (8.13.5/8.13.5) with ESMTP id jA4HFhje003827 for ; Fri, 4 Nov 2005 12:15:44 -0500 (EST) Original-Received: from linus.johnson.com (localhost.johnson.com [127.0.0.1]) by linus.johnson.com (8.12.8/8.12.8) with ESMTP id jA4HGsgd025588 for ; Fri, 4 Nov 2005 08:16:54 -0900 Original-Received: (from tim@localhost) by linus.johnson.com (8.12.8/8.12.8/Submit) id jA4GcS1m024335 for help-gnu-emacs@gnu.org; Fri, 4 Nov 2005 07:38:28 -0900 Original-To: help-gnu-emacs@gnu.org Mail-Followup-To: Tim Johnson , help-gnu-emacs@gnu.org Content-Disposition: inline In-Reply-To: <20051103203316.GA29396@SDF.LONESTAR.ORG> User-Agent: Mutt/1.4.2.1i X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:30831 Archived-At: * Neon Absentius [051103 11:45]: > On Wed, Nov 02, 2005 at 08:19:14AM -0900, thus spake Tim Johnson: > It is explained nicely in the elisp manual: > > ,----[ (info "(elisp) Regexp Special") ] > | `\' > | has two functions: it quotes the special characters (including > | `\'), and it introduces additional special constructs. > | > | Because `\' quotes special characters, `\$' is a regular > | expression that matches only `$', and `\[' is a regular expression > | that matches only `[', and so on. > | > | Note that `\' also has special meaning in the read syntax of Lisp > | strings (*note String Type::), and must be quoted with `\'. For > | example, the regular expression that matches the `\' character is > | `\\'. To write a Lisp string that contains the characters `\\', > | Lisp syntax requires you to quote each `\' with another `\'. > | Therefore, the read syntax for a regular expression matching `\' > | is `"\\\\"'. > `---- > > You see, for the regular expression parser of emacs certain > characters have to be escaped for example "|" when one uses it to > indicate disjunction, so you write it "\|". However when you write > a Lisp program the regexp is entered as a string, and since "\" is > an elisp escape character a sting that contains "\|" is interpreted > as "|". You don't want that, you want the string to pass to the > "regexp machine" as is, you want the regexp to have "\|"; therefore > you have to escape the slash thus "\\|". > > I hope this makes some sense. Indeed. Thank you very much Neon. FYI: I use both Xemacs and GNU emacs. I note that from emacs and in invoking 'info' from the bash shell that I can not find a Menu item for emacs or elisp. It looks as if those components are not installed. In Xemacs, info provides "Lispref: (lispref)" as a menu item, which leads me to the regex topic. For GNU emacs, how may I install these missing items? cheers tim -- Tim Johnson http://www.alaska-internet-solutions.com