This reply is on a new thread but since you mentioned the solution with 
duck-typing, of which I was aware, I have a related question. Assuming I 
know that this function will be applied to only types T1 or T2, is it 
better to use the second solution with Union in terms of performance? I 
would assume so but am no expert in this field...

Reply via email to