ModuleInfo, factories, and unittesting

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Mon Dec 19 10:27:58 PST 2016


On 12/19/16 1:25 PM, Basile B. wrote:
> On Sunday, 18 December 2016 at 16:53:24 UTC, Andrei Alexandrescu wrote:
>> Compulsive ModuleInfo generation seems to be a drag. I'm not very
>> familiar with the particulars but my understanding is ModuleInfo is
>> needed for (a) Object.factory and (b) finding and running unittests.
>>
>> Walter and I think Object.factory was a mistake and we'd like to make
>> it opt-in long term (either by means of a build flag or a class
>> attribute).
>>
>> Until then, a very nice step forward is to NOT generate ModuleInfo if
>> a module introduces no class.
>>
>> For unittests, I figure things like static introspection should make
>> it easier to enumerate and run unittests without a need for ModuleInfo.
>>
>> What other issues/opportunities do you see related to ModuleInfo?
>>
>>
>> Thanks,
>>
>> Andrei
>
> Factory without auto generated info is possible.
> It needs works. Tried before:
> https://github.com/dlang/phobos/pull/4062

Thanks! -- Andrei


More information about the Digitalmars-d mailing list