Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: YAPAQ

From: ptretter:charter at: 2-Mar-2004 10:17

load {word1 word2 "expression 1" "expression 2" word3 "expression 3"} ----- Original Message ----- From: "Hallvard Ystad" <[hallvard--ystad--oops-as--no]> To: <[rebol-list--rebol--com]> Sent: Tuesday, March 02, 2004 7:53 AM Subject: [REBOL] YAPAQ
> Hi, > > YAPAQ: Yet Another PArse Question > > I know this has been asked before, but the list archives are so full of
parse emails that I couldn't find it. Here goes:
> I want to parse a string like this: {word1 word2 "expression 1"
expression 2 word3 "expression 3"}
> and I want the output to be: ["word1" "word2" "expression 1" "expression
2" "word3" "expression 3"]
> So I need a parse rule that considers quotation marks and treats anything
between quotation marks as one single entry. I'm lazy, and don't want to write it myself if someone else already has. I think someone has. Does anyone remember having seen such a parse rule? And where?