oreillymedia / docbook2asciidoc

XSL for transforming DocBook to AsciiDoc
MIT License
61 stars 33 forks source link

Less-than, Greater-than, and Ampersand entities in code listings in DocBook must be resolved in AsciiDoc #23

Open sandersk opened 12 years ago

sandersk commented 12 years ago

Having entities in code like the following in AsciiDoc:

----
#import <UIKit/UIKit.h>
----

Is problematic, because the ampersands get escaped when roundtripped back to DocBook, resulting in the following:

<programlisting>#import &amp;lt;UIKit/UIKit.h&amp;gt;</programlisting>

Less-than, Greater-than, and Ampersand entities should be resolved to <, >, and & in DB->ASC conversion to prevent this problem.