[cfe-commits] [PATCH] Comment parsing: resolve HTML character references (e.g., & -> &)

Jordan Rose jordan_rose at apple.com
Wed Jul 25 14:51:31 PDT 2012


This seems like a very bad idea when I have this in a comment:

<em>0<i</em>

If you expand the '<', you end up with invalid HTML. Entities are supposed to be entities when they come out the other end.

Either Doxygen comments can contain HTML, or they can't. Please don't mix the two.


On Jul 25, 2012, at 14:38 , Dmitri Gribenko <gribozavr at gmail.com> wrote:

> Hello,
> 
> The attached patches implement resolving of HTML character references
> (named: &, decimal: *, hex: &#x1a;) during comment parsing.
> With these patches in place, internal representation of plain text in
> comment AST will not contain character references, but the characters
> themselves.
> 
> Dmitri
> 
> -- 
> main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
> (j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/
> <convert-unicode-code-point-to-utf8-v1.patch><character-references-v1.patch>_______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120725/9c4851e4/attachment.html>


More information about the cfe-commits mailing list