September 27, 2008 [Issue 2377] New: ICE with wrong return type for templated method: template.c:784 | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=2377 Summary: ICE with wrong return type for templated method: template.c:784 Product: D Version: 2.019 Platform: PC OS/Version: Linux Status: NEW Keywords: ice-on-invalid-code Severity: normal Priority: P3 Component: DMD AssignedTo: bugzilla@digitalmars.com ReportedBy: dhasenan@gmail.com Error message: dmd: template.c:784: MATCH TemplateDeclaration::deduceFunctionTemplateMatch(Loc, Objects*, Expression*, Expressions*, Objects*): Assertion `i < parameters->dim' failed. Aborted Test case: --- int call (TReturn) () { return "hello"; } void main () { call!(void)(); } --- -- |
October 03, 2008 [Issue 2377] ICE with wrong return type for templated method: template.c:784 | ||||
---|---|---|---|---|
| ||||
Posted in reply to d-bugmail | http://d.puremagic.com/issues/show_bug.cgi?id=2377 bugzilla@digitalmars.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WORKSFORME ------- Comment #1 from bugzilla@digitalmars.com 2008-10-02 19:05 ------- I get: test5.d(4): Error: cannot implicitly convert expression ("hello") of type invari ant(char[5u]) to int test5.d(9): template instance test5.call!(void) error instantiating which is correct. I cannot duplicate the problem. Works correctly with D 1 too. -- |
Copyright © 1999-2021 by the D Language Foundation