Bug 3515 – Disallow use of comma operator when declaring array dimension

Status
RESOLVED
Resolution
FIXED
Severity
trivial
Priority
P2
Component
dmd
Product
D
Version
D1 (retired)
Platform
All
OS
Linux
Creation time
2009-11-16T13:39:00Z
Last change time
2014-04-18T09:12:04Z
Assigned to
nobody
Creator
procode

Comments

Comment #0 by procode — 2009-11-16T13:39:24Z
Declaring an array using the comma operator can be mistaken for declaring a multi-dimensional array as such form is common in other languages. int[3,4,5] xyz; writefln( "xyz.length=%d", xyz.length); Prints xyz.length = 5 Whilst a trivial issue,one would hope that this does not make it into D2.
Comment #1 by clugdbug — 2010-01-10T11:37:17Z
Fixed DMD2.037.