-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
auto sumtypechain(Rs...)(Rs rs){
//alias E=SumType!(staticMap!(ElementType,Rs));
alias E=SumType!(NoDuplicates!(staticMap!(ElementType,Rs)));//snar this requirment is bad design
return mapchain!(a=>E(a))(rs);
}
unittest{
sumtypechain("abc",[1,2,3],iota(0,100),[13.37,4.20]).writeln;
}combining ranges with an overloaded function that happen to return the same type if implemented at this abstraction level, trivializes the problem, where otherwise its a nightmare
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels