metaeducation / rebol-issues

6 stars 1 forks source link

Double quote escaping for SPLIT #1079

Open rebolbot opened 15 years ago

rebolbot commented 15 years ago

Submitted by: BrianH

Simple PARSE almost implements CSV-style quote handling, but is missing the "" method to do embedded quotes. If we add that we could handle more CSV-style data. The delimiters and quotes otherwise work just fine.

Just follow the RFC: http://tools.ietf.org/html/rfc4180

This ticket is derived from #1042.

; Current behavior
>> parse {"hello""world^/",a} "," 
== ["hello" "world^/" "a"] 
>> length? parse {"hello""world^/",a} "," 
== 3 

; Proposed behavior according to RFC 4180
>> parse {"hello""world^/",a} "," 
== [{hello"world^/} "a"] 
>> length? parse {"hello""world^/",a} "," 
== 2

CC - Data [ Version: alpha 70 Type: Wish Platform: All Category: Parse Reproduce: Always Fixed-in:none ]

hostilefork commented 3 years ago

There is no "simple parse" any longer, but this could be a modality for SPLIT.