Bug 14391 – Assigning to module results in unhelpful error message

Status
NEW
Severity
enhancement
Priority
P4
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-04-02T00:51:12Z
Last change time
2024-12-13T18:41:46Z
Keywords
diagnostic
Assigned to
No Owner
Creator
Vladimir Panteleev
Moved to GitHub: dmd#18967 →

Comments

Comment #0 by dlang-bugzilla — 2015-04-02T00:51:12Z
/// a.d /// module a; int a; /// b.d /// import a; void main() { a = 42; } /////////// Compiler says: b.d(4,5): Error: a is not an lvalue Ideally, it should say something along: b.d(4,5): Error: cannot assign to module "a", did you mean "a.a" of type "int"?
Comment #1 by robert.schadek — 2024-12-13T18:41:46Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18967 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB