stevedlawrence commented on PR #981:
URL: https://github.com/apache/daffodil/pull/981#issuecomment-1460762916

   Sounds like maybe `emptyValueDelimiterPolicy` is just completely broken/not 
implemented then? We might want to consider how to best implement each of these 
instead of doing one at a time, there might be a very clean solution.
   
   My first insinct is that maybe we need a new combinator? So a new parser 
that accepts three sub parsers (initiator, content, and terminator). It parses 
each of these allowing some to fail depending on the 
`emptyValueDelimiterPolicy` and the whether the parsed content was empty.
   
   And the Unparse combinator would look at the value of content, and if empty 
then it unparses the initiator/terminator based on the policy.
   
   This way delimiters don't need to know if they should be optional or not, 
and they don't have to worry about the content being empty or not. They just do 
what they do, and if they fail, the combinator that controls them handles it 
accordingly.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to