Hej,
I have that :
class Test {
static function main() {
go( Macro.getInt() );
}
static function go( n : Int ){
trace( n );
}
}
And then that :
//use this for macros or other classes
class Macro {
public static macro function getInt(){
return macro "Foo";
}
}
When I compile I get an error, ok, but how to do to get the position in the call go( Macro.getInt() );
and not in the macro :
Macro.hx:4: characters 16-21 : String should be Int
Macro.hx:4: characters 16-21 : ... For function argument 'n'
Test.hx:1: lines 1-9 : ... Defined in this class
Here is the example : Try Haxe !