[REBOL] Re: Newbie find question ctd....
From: volker::nitsch::gmail::com at: 28-Jun-2005 10:05
BTW, using [%"" = string] instead of [tail? string].
Thats a nice trick, never thought about it.
Does an implicit none-check, sometimes handy.
On 6/27/05, Anton Rolls <[antonr--lexicon--net]> wrote:
> Hmm, that seems to work..
> It looks like a subtlety of /match is that /tail
> now forces a match to the tail of the series otherwise
> none is returned. It looks like a good feature, though
> it is not obvious from the inline help.
>
> Let me just say again that I am familiar for some years
> with the test:
>
> %"" = find/any/match file pattern
>
> and
>
> find/any/match/tail file pattern
>
> is probably a better replacement (but unproven to me yet).
>
> Anton.
>
> > how about
> > find/match/any/tail
> >
> > >> find/match/any/tail "p3.htm.html" "p?.htm"
> > == none
> > >> find/match/any/tail "p3.htm" "p?.htm"
> > == "p3.htm"
> > >>
> >
> > AR
> >
> >
> > Anton Rolls wrote:
> >
> > >Yes, these cases are handled by the test:
> > >
> > > %"" = find/any/match file pattern
> > >
> > >eg.
> > >
> > > foreach file [
> > > %p1.htm
> > > %p2.htm
> > > %p33.htm
> > > %p.htm.000
> > > ][
> > > if %"" = find/any/match file "p?.htm" [print file]
> > > ]
> > >
> > >Anton.
>
> --
> To unsubscribe from the list, just send an email to
> lists at rebol.com with unsubscribe as the subject.
>
--
-Volker
Any problem in computer science can be solved with another layer of
indirection. But that usually will create another problem.
David
Wheeler