Bug 6704 – CommaExpression as an IfCondition

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
Other
OS
All
Creation time
2011-09-20T23:12:00Z
Last change time
2012-01-21T00:18:10Z
Keywords
rejects-valid
Assigned to
nobody
Creator
k.hanazuki

Comments

Comment #0 by k.hanazuki — 2011-09-20T23:12:02Z
The following code is valid according to the spec but rejected by dmd with the error: test.d(3): if (v; e) is deprecated, use if (auto v = e) Tested with DMD v2.055 ---- void main() { int a; if(a, true) { } }
Comment #1 by github-bugzilla — 2012-01-21T00:17:09Z