ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Devienne <>
Subject Re: bug in DOMElementWriter
Date Mon, 28 Jun 2010 02:14:47 GMT
On Sun, Jun 27, 2010 at 8:55 PM, Jon Stevens <> wrote:
> However, the character that went into the attribute was not a \n, it was a
> &#10;. I'd expect ant to give me &#10; back out, not \n. The point of
> <echoxml> is to echo xml, is it not? In that case, the point here should be
> to echo out the encoded value as xml, not something that is useless.

Jon, in XML land &#10; *is* \n, whatever you say about it.


You *can* have a plain '\n' char (i.e. an actual LF, not '\\' and 'n')
in XML, and for the parser that's the *same*.

Furthermore, whatever you feed your <echoxml>-generated XML file to,
will / should not care either whether it see a '\n' or a "&#10;" if it
uses a compliant XML parser.

Don't get hand up on the textual  representation of the XML file. This


and this


is exactly the same thing as far as XML is concerned.

If you absolutely want your &#10; in the <echoxml> output, you must
follow Antoine's advice.

I suggest you read more on XML and again Ant, for better or worse,
uses an XML parser so will only see '\n' and not your XML char entity.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message