October 14, 2013 [Issue 11249] New: MapResult failed semantic analysis | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=11249 Summary: MapResult failed semantic analysis Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: regression Priority: P2 Component: DMD AssignedTo: nobody@puremagic.com ReportedBy: deadalnix@gmail.com --- Comment #0 from deadalnix <deadalnix@gmail.com> 2013-10-13 22:23:55 PDT --- $ cat fail.d module fail; import std.algorithm; class A { A[] as; } class B { A[] as; } A visit(A a) { a.as.map!(a => visit); return null; } A visit(B b) { b.as.map!(a => visit); return null; } A visit() { return null; } $ ../dmd/src/dmd -c -offail.o fail.d ../dmd/src/../../phobos/std/algorithm.d(415): Error: struct fail.visit.MapResult!(__lambda2, A[]).MapResult failed semantic analysis ../dmd/src/../../phobos/std/algorithm.d(425): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(430): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(436): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(448): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(454): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(459): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(471): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(479): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(496): Error: this for _input needs to be type MapResult not type MapResult!(__lambda2, A[]) ../dmd/src/../../phobos/std/algorithm.d(411): Error: template instance fail.visit.MapResult!(__lambda2, A[]) error instantiating fail.d(18): instantiated from here: map!(A[]) fail.d(18): Error: template instance fail.visit.map!((a) => visit).map!(A[]) error instantiating -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
October 14, 2013 [Issue 11249] MapResult failed semantic analysis | ||||
---|---|---|---|---|
| ||||
Posted in reply to deadalnix | http://d.puremagic.com/issues/show_bug.cgi?id=11249 Kenji Hara <k.hara.pg@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |DUPLICATE --- Comment #1 from Kenji Hara <k.hara.pg@gmail.com> 2013-10-13 22:53:28 PDT --- I have posted a compiler fix for issue 11230, so mark this as a duplicate. *** This issue has been marked as a duplicate of issue 11230 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation