← Back to index
|
Original Bugzilla link
Bug 18101 – allow Tuple for BetterC
Status
RESOLVED
Resolution
FIXED
Severity
enhancement
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2017-12-18T14:26:48Z
Last change time
2020-01-28T01:23:44Z
Keywords
betterC
Assigned to
No Owner
Creator
changlon
See also
https://issues.dlang.org/show_bug.cgi?id=18472
Comments
Comment #0
by changlon — 2017-12-18T14:26:48Z
=============== code =============== import std.typecons : Tuple; alias BOMSeq = Tuple!(int, "schema"); extern(C) int main(){ return 0; } ========================= ../src/phobos/std/range/primitives.d(405): Error: static assert "Cannot put a const(char)[] into a Appender!string." ../../src/phobos/std/format.d(1172): instantiated from here: put!(Appender!string, const(char)[]) ./../src/phobos/std/format.d(473): instantiated from here: writeUpToNextSpec!(Appender!string) ../../src/phobos/std/format.d(5831): instantiated from here: formattedWrite!(Appender!string, char, ulong, ulong) ../../src/phobos/std/typecons.d(542): instantiated from here: format!(char, ulong, ulong) test.d(4): instantiated from here: Tuple!(int, "schema")
Comment #1
by greensunny12 — 2017-12-21T13:46:43Z
The error has been fixed in I opened a PR to add a betterC testsuite to Phobos
https://github.com/dlang/phobos/pull/5952,
but it still doesn't look like it can work.
Comment #2
by moonlightsentinel — 2020-01-28T01:23:44Z
Works for current HEAD