Bug 13062 – "member x is not accessible" when passing field to template parameter
Status
RESOLVED
Resolution
DUPLICATE
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-07-07T06:29:00Z
Last change time
2014-07-31T03:55:57Z
Assigned to
nobody
Creator
doob
Comments
Comment #0 by doob — 2014-07-07T06:29:52Z
The following code worked fine in DMD 2.064.2:
module foo;
static int f(A...)() { pragma(msg, typeof(A)); return 0; }
module bar;
import foo;
struct S { private int x; enum y = f!x(); }
With DMD 2.065.0 I get this error: "Error: struct bar.S member x is not accessible". To me this looks very similar to issue 11946 [1], but Walter wants me to create a new issue [2].
[1] https://issues.dlang.org/show_bug.cgi?id=11946#c42
[2] https://issues.dlang.org/show_bug.cgi?id=11946#c40
Comment #1 by k.hara.pg — 2014-07-31T03:55:57Z
The root is same with issue 11946.
*** This issue has been marked as a duplicate of issue 11946 ***