Bug 7241 – std.format can't read into array of dchar
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2012-01-06T23:30:00Z
Last change time
2012-01-31T02:13:25Z
Keywords
patch, rejects-valid
Assigned to
andrei
Creator
jlquinn
Comments
Comment #0 by jlquinn — 2012-01-06T23:30:36Z
Compiling the following code gives:
import std.stdio;
void foo() {
File f;
dchar[1] dc;
f.readf("%s", dc);
}
dmd -c junk2.d
/usr/include/d/dmd/phobos/std/format.d(439): Error: using * on an array is deprecated; use *(_param_2).ptr instead
This worked in dmd 2.056. My reading of the docs says it should work :-)
Comment #1 by andrei — 2012-01-24T09:19:44Z
The fixed test code:
import std.stdio;
void foo() {
File f;
dchar[1] dc;
f.readf("%s", &dc);
}
also doesn't work :o). I'll look into this.