comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: bug in stregex?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: bug in stregex? [message #31526] Fri, 19 July 2002 18:07 Go to previous message
William Daffer is currently offline  William Daffer
Messages: 34
Registered: February 1999
Member
Craig Markwardt <craigmnet@cow.physics.wisc.edu> writes:

> Vapuser <vapuser@catspaw.jpl.nasa.gov> writes:
>> I don't you, you tell me. Is this a bug?
>>
>> IDL> tt=stregex('cdefaz',"(.*)(a|b|c)z",/extract)
>> IDL> help,tt
>> TT STRING = 'cdefaz'
>>
>> My understanding of regular expressions says it's a bug. The first
>> '(.*)' should only match up to the 'a' and the second subexpression,
>> since it is *unqualified*, should handle the 'az', i.e. TT should
>> have two parts. tt[0] should be 'cdef' and tt[1] should be 'a.'
>
> Hi--
>
> Why don't you try the /SUBEXPR keyword? That seems to do the trick.
>



Well, duh! It's amazing what one can learn actually *reading* the
help file! ;-)

Thanks for pointing me to my rather obvious mistake.

whd
--
NOMINEE, n. A modest gentleman shrinking from the distinction of
private life and diligently seeking the honorable obscurity of public
office.
-- Ambrose Bierce: _The Devil's Dictionary_
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: where are the user defined macros saved?
Next Topic: Urgent help! Could anyone send me a simple algorithm for Maximum Intensity Projection(MIP)?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 05:44:50 PDT 2025

Total time taken to generate the page: 0.16045 seconds