Open jarredbarber opened 5 years ago
Note that Core.println actually throws a different error:
ArgumentError: nothing
should not be printed; use show
, repr
, or custom output instead.
I still don't really understand the difference between Main.println and Core.println but this might be related to the async IO comments on the Julia slack.
Notes from my exploration today. You shouldn't need to untag yourself. recurse
should to that, but we seem to put something into a tuple instead of splatting it.
Looks like the ntuple-ing on L448 in context.jl:
@inline call(context::ContextTagged, f, args...) = untag(f, context)(ntuple(i -> untag(args[i], context), Val(nfields(args)))...)
Will try a few things if I have time today.
@vchuravy I edited the example to not manually untag things.
The following code should produce the same output twice. However, when tagging is enabled, wildly different code branches seem to be taken, and the tagging version fails with a
MethodError
Code:
When
IdentityCtx
runs (first 20 lines):When the
TaggingCtx
runs (first 20 lines)j:The
IdentityCtx
case runs to the end, but the tagging one fails after some number of lines, with a very deep stack trace (43 entries):