I see. So basically, there’s no way to change a Routine’s (Thread’s actually) environment reference “from the outside”, after it has been created? So the only solution is to “unwrap” the routine’s function and only create the Routine proper from the right/desired environment?
If that’s the case then there’s no solution for the equivalence I was seeking short of using “naked routine bodies” (i.e. functions that yield, everywhere)… I’m guessing that’s why
embedInStream is done like this (and it’s also prone to infinite loops in
Pn etc., if the inner pattern doesn’t yield.)
(Asde: I find it rather unpleasant that neither the help page of Routine, nor that of Thread mention environments at all, and so not a peep in there about this startup environment capture…)