Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix overzealous autothreading of Junctions even on Mu parameters
A Mu type constraint on a parameter is supposed to avoid autothreading of junctions for that parameter. Usually this is ensured by the the dispatcher only considering autothreading on bind failures. However when there are multiple Junction arguments, it's possible that some should be passed through (i.e. Mu type constraints on the parameters) and some should be autothreaded. AUTOTHREAD did not take this into account and blindly threaded over all Junction arguments. This led to errors when what was passed was actually a scalar container holding a Junction and the routine wanted to assign into this container. Fix by checking each parameter's type before deciding to autothread. Sadly this does not yet work for protos as auto-generated protos will report Mu as type constraint for all parameter. But it's at least a step in the right direction. Adding the additional check to AUTOTHREAD required us to avoid it for method calls on Junctions and CALL-ME as for the invocant or callee respectively we do want to autothread, despite the permissive type constraints. Anyway, having specialized code for those cases is better for performance anyway.
- Loading branch information