[Issue 9198] Vararg functions don't respect IFTI rules

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Dec 23 03:38:29 PST 2012


http://d.puremagic.com/issues/show_bug.cgi?id=9198



--- Comment #1 from Kenji Hara <k.hara.pg at gmail.com> 2012-12-23 03:38:28 PST ---
(In reply to comment #0)
> I'm not sure *what* said rules are, but as observed here:
> https://github.com/D-Programming-Language/phobos/pull/1010#discussion_r2418181
> 
> The root issue is that IFTI should cast an immutable slice to a slice of
> immutables, but that doesn't happen with varargs:
> 
[snip]
> 
> I'm not sure what the rules are, but I'd expect seeing something consistent in
> any case.

This behavior has been introduced from 2.057.

http://dlang.org/changelog#new2_057
> Removed top const from dynamic array types and pointer types in IFTI.

https://github.com/d-programming-language/dmd/commit/cc0cde2345e6921fc28bd688a503b03fc98f8b93

And, from the view of implementer, this behavior is definitely a bug. Because I
did consider nothing about variadic template parameter.

-- 
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