[Issue 10574] "auto ref" fails to match when IFTI succeeds (strip to level const)
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jul 8 12:10:27 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10574
Steven Schveighoffer <schveiguy at yahoo.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |schveiguy at yahoo.com
--- Comment #1 from Steven Schveighoffer <schveiguy at yahoo.com> 2013-07-08 12:10:26 PDT ---
For clarification, the error displayed for the given code is:
Error: template testautoref.foo(T)(auto ref T[] i) cannot deduce template
function from argument types !()(immutable(int[]))
And it does match immutable(int)[]. As implied, if you change to
version(none), it does indeed work.
const(int[]) also fails.
A workaround that seems to work, but I don't really like it, is to add
overloads for immutable(T[]) and const(T[])
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list