std.concurrency : sending immutable classes

Jonathan M Davis jmdavisProg at gmx.com
Mon Nov 11 15:15:26 PST 2013


On Monday, November 11, 2013 21:10:20 Dicebot wrote:
> On Monday, 11 November 2013 at 19:18:20 UTC, Gary Willoughby
> 
> wrote:
> > On Monday, 11 November 2013 at 18:54:04 UTC, Dicebot wrote:
> >> Any ideas? :)
> > 
> > This is one way:
> > 
> > ...
> 
> No, I am perfectly aware of shared part, point is exactly about
> sending immutable ones (which are implicitly shared by design).
> What bothers me most is that I can't imagine what code flow it
> takes to print no output and no errors as (Variant v) is supposed
> to catch everything.

Maybe it missed the Variant due to a mismatch in constness? In my experience, 
receive is _very_ picky about the type. It pretty much has to match exactly, 
and while Variant may work to get the stuff that misses in most cases, it 
wouldn't surprise me at all if a difference in constness threw it off. But 
that's just a guess. I'd have to go digging through the code and experiment to 
figure out why what you're doing isn't working.

- Jonathan M Davis


More information about the Digitalmars-d-learn mailing list