Open fsaad opened 1 year ago
Seems like the issue is that we're hardcoding how the :continuous
annotation gets parsed by the macro:
The fixed definition would be something like:
macro read(src, ann)
_typed = GlobalRef(Gen, :typed)
return quote read($(esc(bij_state)), $(esc(src)), $(_typed)($(esc(ann.value)))) end
end
The downside is that it would lead to a somewhat slower dynamic call to the typed
function at run-time, instead of handling that logic at compile time. I'm not sure how much slower, but perhaps it's worth not making the switch and just clearly documenting that the user has to directly specify whether they want something to be :continuous
or :discrete
.