خرید بک لینک

Vote count: 0

I'm trying to debug a library which uses haxe.macro.TypeTools::findField. I've created a simple code for that:

package;

using haxe.macro.TypeTools;

class Main
{   
    public function new()
    {   
        var test = findField(Child, "hello");
        trace(test);
    }
}

class Base
{
    private function hello()
    {
    }
}

class Child extends Base
{
    public function new() {}
}

However I'm getting error Unknown identifier : findField. Is this because it can only be used in build macro context?

https://github.com/fponticelli/edge/blob/3b4623172c0ecc426a940cc0c9d34c7e660ce8a2/src/edge/core/macro/BuildSystem.hx#L57 - this is what I'm trying to emulate.

Thank you!

asked 55 secs ago

- - , .
.

برچسب: نویسنده: استخدام کار تاريخ: پنجشنبه 24 تير 1395 ساعت: 3:28

صفحه بندی