mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-01-12 02:43:14 +01:00
19 lines
260 B
D
19 lines
260 B
D
module bug60;
|
|
extern(C) int printf(char*, ...);
|
|
|
|
void func(T...)(T t)
|
|
{
|
|
foreach(v;t) {
|
|
if (v.length) {
|
|
foreach(i;v) {
|
|
printf("%d\n", i);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
void main()
|
|
{
|
|
auto a = [1,2,3];
|
|
func(a);
|
|
}
|