This message should be improved: ----- /usr/local/opt/dmd/include/dlang/dmd/std/concurrency.d(449,5): Error: static assert: "Aliases to mutable thread-local data not allowed." mod.d(171,30): instantiated from here: `spawn!(void function(Config) @system, Config)` mod2.d(48,25): instantiated from here: `__ctor!(Config)` ----- It doesn't say which field is the offending one, just that there is some pointer or array somewhere, but it's really hard to determine what is the offending field when the data structure is complex. With all the traits power D has, emitting the field name should be possible.
Alternative: Make the ` hasLocalAliasing` function public. That way we can add the check to composite types on our own.
Actually I've just noticed it just uses std.traits.hasUnsharedAliasing internally, so never mind about the last suggestion.
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/phobos/issues/10373 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB