Uli Kuster wrote:
> > find "<A HREF=" & a string theUrl & ">"...
>
> of all your proposal I like this best.
Thanx!
> Although we might want to drop the "a", that is:
>
> find expression "<A HREF=" & string theURL & ">"
>
> Of course, once this expression is found, the foundChunk would contain the
>start and end positions of the whole expression found, and we could parse
>it for its parameters. or we could have a new function like param() which
>allows returning the wildcard, i.e. wildcard(1) or something like that (I
>can't seem to come up with a good name right now). Maybe we'd write:
>
> find expression "<A HREF=" & wildcard string theURL & ">"
>
>Although we'd lose some English-like-ness this way.
The point of naming the wildcard "theURL" was to have the string
matching the wildcard put into a variable with that name. An
alternative would be a function as you suggest (I like
wildcardChunk(1) and wildcardText(-1) best). It was my mistake to
suggest a new chunk type "the first found chunk" or to name that
function "foundChunk".
> > find "(" & a string txt & ")" or "[" & a string txt & "]" or ...
>
> I don't like this. What if someone wants a boolean expression in there?
>I.e. look for "something<*>=TRUE" or "something<*>=FALSE" when scanning
>some cryptic codes? I think we'd best work around it this way:
>
> find expression ... or expression ...
>
>by prefixing both with "expression", we differentiate between find "string"
>and find expression, and since "or expression" can't be mixed up with "or"
>in a boolean expression, this would work (except if someone had a variable
>named "expression" and did an "or" on it, but that's tough luck.
"expression" would be a reserved word, you can't name your variables
"expression" or "or". So that is not a problem, but I don't think it
is necessary to add the keyword "expression" to each "or". I think if
you need a boolean expression, you can place them in brackets:
find "something<" & a string block1 &">"& (var1="x" or var2="y") \
or "something<" & a string block2 &">"& (var3="x" or var4="y")
This is very well readable, isn't it?
Regards
R�diger
--------------------------------------------------------------------
| Ruediger zu Dohna GINIT GmbH 0721-96681-63 [EMAIL PROTECTED] |
| PGP-Fingerprint: F1 BF 9D 95 57 26 48 42 FE F8 E8 02 41 1A EE 3E |
--------------------------------------------------------------------