Re: [xml] Are there any chance to keep single quotes as attribute text boundary?

On 11/12/2010, Nikolay Shaplov <n shaplov ru> wrote:

This is not diff safely :-/

Are there any chance to keep formatting as it were, at least for
elements that were not changed during tree elements manipulation? May
be there is some parsing options I do not know of?

This kind of formatting is not in the infoset[0] so not preserved from parsing.

The general solution to your problem with text diffs is to
consistently output a canonical form[1], which will ensure the
serialised representation won't change if the stuff you care about


[0] What is not in the Information Set
"17. The kind of quotation marks (single or double) used to quote
attribute values."
[1] The libxml2 "Canonical XML" implementation

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]