What's wrong with std.variant.Variant?

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Sat Jun 13 19:10:04 UTC 2020


I was curious about collecting a list of grievances about Variant. It's 
the oldest piece of generic code in std, and it predates a lot of good 
language additions.

So what's wrong with Variant? One thing I collected from a coworker is 
that it doesn't work with Windows DLLs, because in turn typeof() 
comparison does not work across Windows DLLs.

What are other problems with it?


More information about the Digitalmars-d mailing list