I was about to write my very first haxe macro but I need the returned expression to be platform-specific, is there any way to do that ? Maybe differently ?
Here is the code, I also tried to have one “count_args” function per platform but it doesn’t seem to work either (compiler says the function doesn’t exist)
The $ character triggers expression reification in macros. I think you need to use expression reification to work around the expression reification (whoa…).
my head !
It makes sense, but compiler complains about “unknown identifer” with f’s content… no biggie though, I’m currently happy with the static inlined version.
I’ll read the macro docs again, they might make more sense to me now