[Issue 4163] New: if(bool = bool) results in ill-worded error
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri May 7 10:42:35 PDT 2010
http://d.puremagic.com/issues/show_bug.cgi?id=4163
Summary: if(bool = bool) results in ill-worded error
Product: D
Version: 2.041
Platform: x86
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: schveiguy at yahoo.com
--- Comment #0 from Steven Schveighoffer <schveiguy at yahoo.com> 2010-05-07 10:42:33 PDT ---
The following code:
bool x, y;
if(x = y) {}
results in the following error:
Error: '=' does not give a boolean result
Which is clearly not a correct message. A better message would be something
like:
Error: '=' cannot be used inside an if condition
--
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