Skip to content

Instantly share code, notes, and snippets.

@alecmce
Created October 16, 2011 11:49
Show Gist options
  • Save alecmce/1290796 to your computer and use it in GitHub Desktop.
Save alecmce/1290796 to your computer and use it in GitHub Desktop.
describeType to discover uint and int
package
{
import flash.display.Sprite;
import flash.utils.describeType;
[SWF(backgroundColor="#FFFFFF", frameRate="60", width="800", height="600")]
final public class Test extends Sprite
{
public function TestRunner()
{
trace(describeType(new TestClass()));
// <type name="Test.as$0::TestClass" base="Object" isDynamic="false" isFinal="false" isStatic="false">
// <extendsClass type="Object"/>
// <variable name="a" type="int">
// <metadata name="__go_to_definition_help">
// <arg key="pos" value="405"/>
// </metadata>
// </variable>
// <variable name="b" type="uint">
// <metadata name="__go_to_definition_help">
// <arg key="pos" value="424"/>
// </metadata>
// </variable>
// <metadata name="__go_to_definition_help">
// <arg key="pos" value="382"/>
// </metadata>
// </type>
}
}
}
class TestClass
{
public var a:int;
public var b:uint;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment