[Issue 16481] New: invalid code accepted leading to
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Fri Sep 9 06:40:47 PDT 2016
https://issues.dlang.org/show_bug.cgi?id=16481
Issue ID: 16481
Summary: invalid code accepted leading to
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: major
Priority: P1
Component: dmd
Assignee: nobody at puremagic.com
Reporter: john.loughran.colvin at gmail.com
% cat mod.d
void blah()
{
import std.algorithm;
import std.conv;
int[][] a;
a.map!(x => x.map!to);
}
% dmd mod.d
Undefined symbols for architecture x86_64:
"_D3std9algorithm9iteration32__T9MapResultS123std4conv2toTAiZ9MapResult6__ctorMFNaNbNcNiNfAiZS3std9algorithm9iteration32__T9MapResultS123std4conv2toTAiZ9MapResult",
referenced from:
_D3std9algorithm9iteration23__T3mapS123std4conv2toZ11__T3mapTAiZ3mapFNaNbNiNfAiZS3std9algorithm9iteration32__T9MapResultS123std4conv2toTAiZ9MapResult
in mod.o
"_main", referenced from:
implicit entry/start for main executable
(maybe you meant: __d_main_args,
_D4core6thread6Thread7sm_mainC4core6thread6Thread )
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
--- errorlevel 1
That code shouldn't compile (because of using std.conv.to without a target
type), so it should never hit the linker at all.
--
More information about the Digitalmars-d-bugs
mailing list