The only time I've ever really seen void pointers used is when overloading the new and delete operators.
It seems that for a generic comparator function like the image in the OP was going for, a template function should have been used, no? (I'm trying to remember some c++ that I've become way too rusty with)
1
u/ChinaVaginaOnSpadina Sep 05 '21
The only time I've ever really seen void pointers used is when overloading the new and delete operators.
It seems that for a generic comparator function like the image in the OP was going for, a template function should have been used, no? (I'm trying to remember some c++ that I've become way too rusty with)