cvs.gedasymbols.org/archives/browse.cgi   search  
Mail Archives: djgpp/1999/09/29/09:56:45

From: eplmst AT lu DOT erisoft DOT se (Martin Stromberg)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Regexp
Date: 29 Sep 1999 08:20:25 GMT
Organization: Ericsson Erisoft AB, Sweden
Lines: 18
Message-ID: <7ssi49$8ii$2@antares.lu.erisoft.se>
References: <938279461 AT p20 DOT f44 DOT n478 DOT z2 DOT FidoNet DOT ftn>
NNTP-Posting-Host: spica-144.lu.erisoft.se
X-Newsreader: TIN [version 1.2 PL2]
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Oleg Ossovitskii (avatar AT netcity DOT ru) wrote:
: If I write regexp "[ZH]R-(16)" that don't match string ZR-16, but if I write
: "[ZH]R-\\(16\\)" that matched ZR-16 & HR-16, but I need ZR-16 & ZR-32! And if I
: write "[ZH]R-\\(16|32\\)" that don't match nor ZR-16 nor ZR-32 and nor HR-16
: etc. I have gcc 2.95.  Please help me, or sent me via e-mail documentation on
: regexps from djgpp with _examples_.

Well, there are different flavours of regexes. Try the book Mastering
Regular Expressions from O'Reilly for a thorough examination. 
Perhaps the man page for Regex have some information?

Anyway, jugding by what you've said I guess that "[ZH]R-\\(16\\|32\\)"
will match what you want.


Right,

							MartinS

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019