Mitigating the attribute proliferation - attribute inference for functions

Martin Nowak via Digitalmars-d digitalmars-d at puremagic.com
Fri Jul 17 15:06:16 PDT 2015


On Friday, 17 July 2015 at 19:23:23 UTC, Meta wrote:
> What are the specific issues? I've encountered attribute hell 
> as well, but with const/immutable/inout as opposed to 
> pure/nothrow/@nogc/@safe.

Just to name 2 issues.

I can't convert derived classes with a destructor to their base 
class without constructor b/c the latter doesn't have attributes.

https://github.com/MartinNowak/phobos/commit/1bac938f28110f1ab2ba797adae7ab4611245cc2?diff=unified#diff-4e008aedb3026d4a84f58323e53bf017R50
https://github.com/MartinNowak/phobos/commit/1bac938f28110f1ab2ba797adae7ab4611245cc2?diff=unified#diff-4e008aedb3026d4a84f58323e53bf017R274

Inference totally fails if you mix lowlevel library code with 
UDTs, e.g. for constructing, copying, destroying.


More information about the Digitalmars-d mailing list