[Issue 4715] New: Bad error message with update for already defined variable
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Aug 22 19:48:46 PDT 2010
http://d.puremagic.com/issues/show_bug.cgi?id=4715
Summary: Bad error message with update for already defined
variable
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: diagnostic
Severity: minor
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: bearophile_hugs at eml.cc
--- Comment #0 from bearophile_hugs at eml.cc 2010-08-22 19:48:41 PDT ---
This wrong D2 program:
void main() {
int foo = 1;
int foo = 1;
}
Produces a good error message (dmd 2.048):
test.d(3): Error: declaration test.main.foo is already defined
But this similar wrong program:
void main() {
int foo = 1;
int foo -= 1;
}
Produces two wrong error messages:
test.d(3): semicolon expected, not '-='
test.d(3): found '-=' instead of statement
I'd like this second situation to generate the same error as before.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list