Am Mon, 13 Feb 2017 19:49:28 -0800
schrieb Timothee Cour via Digitalmars-d <digitalmars-d@puremagic.com>:

> What about allowing syntax sugar as an alternative to relying on the
> new `from/Module` inline import idiom:
> 
> ```
> void fun(T)(std.stdio::File input, T value) if
> (std.traits::isIntegral!T) {...}
> ```

If you use a single ':' instead you can argue it's simply a shortened,
inline version of a selective import:

import std.stdio : File;
//still valid D
import std.stdio:File;
//expression instead of statement => remove ;
import std.stdio:File
//We're not importing a symbol, we're simply referring to it
std.stdio:File

-- Johannes

Reply via email to