Sunday, 18 August 2013

haxe: 'class not found' when trying to macro @:build fields of an enum

haxe: 'class not found' when trying to macro @:build fields of an enum

In short I'm trying to generate fields of an enum and a class using a
macro. I think I'm following the instructions at
http://haxe.org/manual/macros/build but for some reason I get
peg (master *+)$ haxelib run munit test test.hxml
...
test/ParserTest.hx:8: characters 13-18 : Class not found : Generator
test/TestMain.hx:16: lines 16-62 : Defined in this class
Error: Error compiling hxml for cpp
Target cpp /Users/sakari/work/peg/bin/test/core/cpp_test/
When I try to build the test suite for it with
haxelib run munit test test.hxml
I've got
//ParserTest.tx
import sakari.peg.Generator;
...
#if !macro @:build(Generator.buildAst(Def.rules))

No comments:

Post a Comment