Bug 16322 – Improve error message for missing module declaration

Status
NEW
Severity
enhancement
Priority
P4
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Mac OS X
Creation time
2016-07-26T07:15:59Z
Last change time
2024-12-13T18:49:11Z
Assigned to
No Owner
Creator
Nicholas Wilson
Moved to GitHub: dmd#17767 →

Comments

Comment #0 by iamthewilsonator — 2016-07-26T07:15:59Z
if a file in a structed directory a/b/c/d.d has no module declaration and is imported as `import a.b.c.d` the error message is module d from file a/b/c/d.d must be imported with 'import d;' importing as `import d;` will also fail if (very likely) a/b/c/d is not in the import path. Issue a warning that no module declaration is present, indicating that may be the cause.
Comment #1 by robert.schadek — 2024-12-13T18:49:11Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/17767 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB