phobos dependencies

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Sat Dec 21 13:16:23 PST 2013


On 12/21/13 1:06 PM, Dmitry Olshansky wrote:
> 21-Dec-2013 21:10, Andrei Alexandrescu пишет:
>> On 12/21/13 12:08 AM, Dmitry Olshansky wrote:
>>> 21-Dec-2013 00:43, Martin Nowak пишет:
>
>>>> Couldn't static imports be made lazy without breaking any code?
>>>> The above example would read.
>>>>
>>>> static import std.range.
>>>>
>>>> void foo(R)(R range) if (std.range.isForwardRange!R)
>>>> {
>>>> }
>>>>
>>> That has the disadvantage of importing the whole std.range.
>>
>> Yah but only if the symbol foo is actually used.
>
> That assuming static import becomes lazy (if/when).
>
> In such a case I'd be against the idom still if only because of extra
> verbosity in constraints - it's a place where we'd want to have less of it.

That's why I'm saying: make all imports lazy!!!!


Andrei


More information about the Digitalmars-d mailing list