[Issue 19144] New: Imported package have different protection depending on how it's accessed
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Aug 6 08:58:46 UTC 2018
https://issues.dlang.org/show_bug.cgi?id=19144
Issue ID: 19144
Summary: Imported package have different protection depending
on how it's accessed
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: b2.temp at gmx.com
file1.d ---
import std.stdio;
file2.d ---
import file1;
pragma(msg, __traits(getProtection, __traits(getMember, file1, "std")));
pragma(msg, __traits(getProtection, file1.std));
static assert( __traits(isSame, __traits(getMember, file1, "std"), file1.std));
output:
public
private
instead of
private
private
Bug seems to happen only for packages.
--
More information about the Digitalmars-d-bugs
mailing list