[haXe] New feature : Properties

Nicolas Cannasse ncannasse at motion-twin.com
Thu Apr 13 11:12:37 CEST 2006


> class C {
>     public property x(dynamic,null) : Int;
>     public function new() { }
> }
> 
> var c = new C();
> Reflect.setField(c,"x",function() { return 33; });
> trace(c.x); // 33

Sorry, it was Reflect.setField(c,"get_x",...)

Nicolas



More information about the Haxe mailing list