[Issue 18243] New: selective import + overload = private visibility
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Jan 16 19:03:11 UTC 2018
https://issues.dlang.org/show_bug.cgi?id=18243
Issue ID: 18243
Summary: selective import + overload = private visibility
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: blocker
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: rumbu at rumbu.ro
module a;
private import std.math: isNaN;
//custom overload
public bool isNaN(int i) { return false; }
=============================
module b;
import a;
void foo()
{
bool b = isNaN(float.nan);
//compiles successfully calling std.math.isNaN even it should not be
visible.
}
--
More information about the Digitalmars-d-bugs
mailing list