local import hijacking

H. S. Teoh via Digitalmars-d digitalmars-d at puremagic.com
Thu Jan 14 08:32:38 PST 2016


On Thu, Jan 14, 2016 at 11:09:29AM -0500, Andrei Alexandrescu via Digitalmars-d wrote:
[...]
> Yes, this needs to be fixed. -- Andrei

This issue has been known for a long time:

	https://issues.dlang.org/show_bug.cgi?id=10378

Kenji even has a PR for it.

My favorite blatant demonstration of its nastiness:

	import std.stdio;
	void func(string text) {
		import std.conv;
		writeln(text);
	}
	void main() {
		func("Hello world");
	}

Program output: (blank)


T

-- 
Жил-был король когда-то, при нём блоха жила.


More information about the Digitalmars-d mailing list