[haXe] UTF8 in XML attribute names

Curly Brackets explicit.type at gmail.com
Wed Nov 8 22:45:25 CET 2006


Hi!

If I try to parse an XML file that has non-ASCII characters in attribute names,
I get a following error when using Neko API:

Called from <null> line 1
Called from Main.hx line 22
Called from neko/NekoXml__.hx line 110
Uncaught exception - xml.c(73) : Xml parse error : Expected attribute name at
line 1 : ...ååå="bar">
</foo>

As an attachment is a test case for this error.

CB



-------------- next part --------------
-cp .
-neko test.n
-main Main.hx
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.xml
Type: text/xml
Size: 72 bytes
Desc: not available
Url : http://lists.motion-twin.com/pipermail/haxe/attachments/20061108/84aa9085/test.bin
-------------- next part --------------
class Main
{
	public static function main()
	{
		var content:String = neko.io.File.getContent("test.xml");
		var xmlDoc:Xml = Xml.parse(content);
	}
}


More information about the Haxe mailing list