The "copy" you see in the parse rule is not the same as the copy at the
command line.
Parse rules are made up from a dialect specific to parse. That is, the
"code" you find in a parse rule is not executed like ordinary script, it is
instead interpreted by the parse function. When the parse function
encounters the word "copy" in a parse rule it applies its own specific
meaning - just like you could if you had a function that processed words in
a block.
Check out the documentation on parse and you will find that the result of
using copy (in parse) is to copy the input stream from the current position
for as long as the next match pattern is valid.
In contrast, the bits of code you find in a parse rule between a "(" and a
")" are normal rebol commands. This allows you to have the power of rebol
script from within parse.
Another thing you will see in parse rules is a set-word like "here-i-am:".
Again, when parse encounters this set-word it applies its own specific
meaning, in this case it is to assign the word "here-i-am" to the current
location of the input-stream.
See the documentation for an example of this use.
Hope that explains it.
Brett.
----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, October 04, 2000 10:24 PM
Subject: [REBOL] simple parse and copy question
>
> >> help copy
> USAGE:
> COPY value /part range /deep
>
> considering:
>
> "parse page [thru <title> copy text to </title> ] "
>
> copy is evaluted towars the RIGHT side, copies values into WORD! text
>
> am I to take this as it is? can someone explain exactly why this
> particular example works this way.
>
>
> regards
>
> Sharriff Aina
> med.iq information & quality in healthcare AG
>
>