Bug 15778 – [REG2.064] polysemous string type doesn't work in array operation

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2016-03-08T19:33:11Z
Last change time
2020-03-21T03:56:32Z
Keywords
pull, rejects-valid
Assigned to
No Owner
Creator
anonymous4

Comments

Comment #0 by dfj1esp02 — 2016-03-08T19:33:11Z
void f(wchar[] s) { s[]="a"; } Error: cannot implicitly convert expression ("a") of type string to wchar[]
Comment #1 by ag0aep6g — 2016-03-08T21:00:40Z
The 'regression' severity level indicates that the code works with a previous version of dmd. What version does it work with?
Comment #2 by b2.temp — 2016-03-09T02:33:33Z
void f(wchar[] s) { s[]="a"w; } works. Obviously in the original example it fails because of the encoding of the literal and the one of the target variable is not the same. Did it use to work ? (even with IDEone, dmd 2.067, it fails).
Comment #3 by k.hara.pg — 2016-03-09T15:04:10Z
Introduced in 2.064.
Comment #4 by k.hara.pg — 2016-03-09T15:37:46Z
Comment #5 by github-bugzilla — 2016-03-10T10:55:48Z
Commits pushed to stable at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/f3849978badaf2e07966c2f6c5c8af50486a1b0a fix Issue 15778 - polysemous string type doesn't work in array operation https://github.com/D-Programming-Language/dmd/commit/f1ee0d010a0cdcb7af096f157a18228a9eca0e2f Merge pull request #5511 from 9rnsr/fix15778 [REG2.064] Issue 15778 - polysemous string type doesn't work in array operation
Comment #6 by temtaime — 2016-03-10T14:32:45Z
I'm sorry bugzilla redirects in a strange way Restored status to regression
Comment #7 by github-bugzilla — 2016-03-14T14:43:25Z
Comment #8 by dfj1esp02 — 2016-03-14T14:59:16Z
(In reply to ag0aep6g from comment #1) > The 'regression' severity level indicates that the code works with a > previous version of dmd. What version does it work with? I upgraded from 2.063 :3