Bug 24470 – Type safe variadic arguments of delegates cause implicit conversion into lazy

Status
RESOLVED
Resolution
INVALID
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2024-03-31T01:14:28Z
Last change time
2024-03-31T02:51:47Z
Assigned to
No Owner
Creator
Marcelo Silva Nascimento Mancini

Comments

Comment #0 by msnmancini — 2024-03-31T01:14:28Z
I was just testing into trying to have lazy variadic array of delegates without having to type the delegate manually, I showed people and they proved that this is a bug. ```d void anotherTest(scope void delegate()[] dg...) { import std.range; foreach(d; dg.retro) d(); } void main() { anotherTest( writeln("Hello"), writeln("World") ); } ```