package{ import flash.display.Sprite; public class Main extends Sprite{ public function Main(){ var foo:XML = <a> <b> <c> <b>foo</b> </c> </b> </a>; trace(foo..b.toXMLString()); } } }