Hallvard Ystad napsal(a):

>Hello folks
>
>I have a parse problem again. Hope someone here can help (Brett?).
>
>Heres an example from codeconscious.com:
>
>ws:  charset {^A^B^C^D^E^F^G^H^-^/^K^L^M^N^O^P^Q^R^S^T^U^V^W^X^Y^Z^[^\^]^!^_ 
>^~ }
>input-string: "fox dog"
>parse/all input-string [ [any ws "fox"] [any ws "dog"] ]
>
>The last parse statement returns 'true. But now, what if we use the 'to:
>
>input-string: "let's make a new speciaes: a fox dog"
>parse/all input-string [ to [any ws "fox"] [any ws "fox"] [any ws "dog"] ]
>** Script Error: Invalid argument: any ws fox
>** Near: parse/all input-string [to [any ws "fox"] [any ws "fox"] [any ws 
>"dog"]]
>
>What did I do wrong? 
>
>It seems that 'to in the parse dialect is very restrictive as to what may 
>follow. The same applies to 'thru.
>
>Please help me someone!
>
>HY
>(Going on holyday tomorrow, reading possible responses after the weekend.)
>
>Prćtera censeo Carthaginem esse delendam
>
>  
>
yes, Hallward, you are right, 'to and 'thru are restricted, while it 
would be useful to have them more universal. You may have a look at mine 
or Gabriele's results published at REP. E.g. mine is: 
http://www.compkarori.com/vanilla/display/TO%2C+THRU+And+NOT+PARSE+Rules

-L
-- 
To unsubscribe from the list, just send an email to 
lists at rebol.com with unsubscribe as the subject.

Reply via email to