On Fri, Jan 22, 2016 at 4:34 PM, <[email protected]> wrote: > Ok this could seem to make no sense, and this actually does not...
It will not work since @eval eval's in the module that calls the macro, you need to use the eval function and supply with the right module. `current_module()` might work but it really depend on what you want to do and what API you are desiging. > Of course it solved the error in this precise case but the point of > generating functions through macros inside the module was precisely because > I have to define a type outside the module that should be used inside one of > the functions of the module. As the module is parsed, this type is not yet > defined... So, obviously, when I use @eval in this case, it miserably fails. > I'll try to come up with a minimal example which describe a bit more what I > want to do.
