Bug 1486 – Can't implicitly convert char[][] to const(char)[][]

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2007-09-07T18:51:00Z
Last change time
2015-06-09T01:14:16Z
Keywords
rejects-valid
Assigned to
bugzilla
Creator
reiner.pope

Comments

Comment #0 by reiner.pope — 2007-09-07T18:51:52Z
The following code fails to compile, with error "cannot implicitly convert expression (a) of type char[][] to const(char)[][]". However, it appears to be a valid operation. void main() { char[][] a; string[] b = a; }
Comment #1 by onlystupidspamhere — 2007-09-07T19:30:19Z
[email protected] wrote: > http://d.puremagic.com/issues/show_bug.cgi?id=1486 > > Summary: Can't implicitly convert char[][] to const(char)[][] > Product: D > Version: 2.004 > Platform: PC > OS/Version: Windows > Status: NEW > Severity: normal > Priority: P2 > Component: DMD > AssignedTo: [email protected] > ReportedBy: [email protected] > > > The following code fails to compile, with error "cannot implicitly convert > expression (a) of type char[][] to const(char)[][]". However, it appears to be > a valid operation. > > void main() { > char[][] a; > string[] b = a; > } > > Finally! I actually knew about this bug some time ago (2-4 months), when I updated some of my D shell scripts to D 2.0. I purposefully didn't report since I wanted to see how long it would take until someone else did. It seemed such a common problem (I have very little D code written, yet I stumbled upon it quickly), that I'm somewhat surprised it took this long for someone to report it. Isn't there that many people using D2.0 features or what?
Comment #2 by bruno.do.medeiros+deebugz — 2008-04-28T19:12:04Z
This works in the latest versions. Please confirm and close the bug. Other related cases still remain buggy though, see #2056.
Comment #3 by bruno.do.medeiros+deebugz — 2008-09-01T18:03:35Z
It's definitely fixed.