[Issue 13884] New: No error line number with std.array.array of range of type tuples
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Sun Dec 21 08:46:27 PST 2014
https://issues.dlang.org/show_bug.cgi?id=13884
Issue ID: 13884
Summary: No error line number with std.array.array of range of
type tuples
Product: D
Version: D2
Hardware: x86
OS: Windows
Status: NEW
Keywords: diagnostic
Severity: normal
Priority: P1
Component: DMD
Assignee: nobody at puremagic.com
Reporter: bearophile_hugs at eml.cc
This is wrong code:
import std.array: array;
import std.algorithm: map;
struct Foo { int x; }
void main() {
[Foo(1)].map!(t => t.tupleof).array;
}
Dmd 2.067alpha shows an error without line number:
Error: no size for type (int)
temp.d(5,19): Error: functions cannot return a tuple
...\dmd2\src\phobos\std\algorithm.d(450,16): instantiated from here:
MapResult!(__lambda1, Foo[])
temp.d(5,13): instantiated from here: map!(Foo[])
--
More information about the Digitalmars-d-bugs
mailing list