Bug 1941 – missing line on inaccesable external private module member

Status
RESOLVED
Resolution
FIXED
Severity
critical
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2008-03-25T12:14:00Z
Last change time
2015-06-09T01:20:08Z
Keywords
diagnostic, patch
Assigned to
nobody
Creator
spam

Comments

Comment #0 by spam — 2008-03-25T12:14:39Z
[mod.d] module mod; private int bar; [main.d] module main; import mod; void main(){bar = 0;} gives dmd compiler output: "main.d: module main mod.bar is private" this message must be improved. it should at least provide a line number to be parsable as every other error message (every other besides the other ones that are broke ;)
Comment #1 by technocrat7 — 2008-03-25T13:28:17Z
I don't know how the compiler works, but here's my guess on the source of the problem (and its solution). src\dmd\dsymbol.c, line 667 (DMD 1.028): error("%s is private", d->toPrettyChars()); should be: error(loc, "%s is private", d->toPrettyChars());
Comment #2 by clugdbug — 2008-07-09T07:12:50Z
Fixed DMD1.032
Comment #3 by spam — 2008-08-10T06:08:21Z
I dont know if it was fixed in the previous version but i know for sure it is still the same bug in 2.018, so i reopen it.
Comment #4 by clugdbug — 2010-05-17T08:19:32Z
This has actually never worked on any version of DMD. Downgrading to critical. The patch still works, though (it is line 847 of dsymbol.c in DMD2.047.
Comment #5 by bugzilla — 2010-05-31T22:48:30Z