Article View: bit.listserv.gnuemacs
Article #1Problem while doing query-replace-regexp
From: Dieter Woerz
Date: Wed, 29 Sep 1993 04:06
Date: Wed, 29 Sep 1993 04:06
28 lines
2192 bytes
2192 bytes
I am annoyed by a feature of emacs in query-replace and query-replace-regexp. When I execute the command query-replace-regexp \(.*\) abc/def/\1/xyz I get different results depending on the input. For the following inputs I get the associated outputs, but I would like to get the string in brackets 1. uvw -> abc/def/uvw/xyz (abc/def/uvw/xyz) 2. Uvw -> Abc/Def/Uvw/Xyz (abc/def/Uvw/xyz) 3. UVW -> ABC/DEF/UVW/XYZ (abc/def/UVW/xyz) As you see, in case 1 I get what I want, but in the cases 2 and 3 I don't. The thing isn't even that predictable. If the source string (uvw) contains a non-alphanumerical character the behaviour of the replace changes to 1. I would like to know, if there is some variable to set, so that I can always get the strings in the brackets. Thanks in advance Dieter -- Zahnaerztliches Rechenzentrum Dr. Gueldener GmbH Dieter Woerz INTERNET: woerz@gueldener.de Postfach 101545 UUCP: unido!zahn!woerz D-70014 Stuttgart BITNET/EARN: woerz%gueldener.de@unido.bitnet
Technical Details
Message-ID:
<1993Sep28.220616.14835@gueldener.de>Path:
arc1-ca.pugleaf.net!gmd.de!xlink.net!subnet.sub.net!nadia!zahn.gueldener.de!zahn!woerzShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10b1cb,1cd9131ba43e5fd9,start X-Google-Attributes: gid10b1cb,public X-Google-Thread: 102b9a,1cd9131ba43e5fd9,start X-Google-Attributes: gid102b9a,public X-Google-Thread: 103b8b,1cd9131ba43e5fd9,start X-Google-Attributes: gid103b8b,public X-Google-Thread: 157b82,1cd9131ba43e5fd9,start X-Google-Attributes: gid157b82,public X-Google-Thread: ff358,1cd9131ba43e5fd9,start X-Google-Attributes: gidff358,public X-Google-Thread: 1184c8,1cd9131ba43e5fd9,start X-Google-Attributes: gid1184c8,public X-Google-ArrivalTime: 1993-09-29 13:02:06 PST Newsgroups: bit.listserv.gnuemacs,comp.emacs,de.comp.gnu,fj.editor.emacs,gnu.emacs.help,zer.t-netz.gnu Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!subnet.sub.net!nadia!zahn.gueldener.de!zahn!woerz From: woerz@gueldener.de (Dieter Woerz) Subject: Problem while doing query-replace-regexp Message-ID: <1993Sep28.220616.14835@gueldener.de> Followup-To: poster Sender: usenet@gueldener.de (Netnews Poster) Organization: Zahnaerztliches Rechenzentrum Dr. Gueldener GmbH, Stuttgart, FRG Date: Wed, 29 Sep 1993 04:06:42 GMT Lines: 28