4 ms·
Because it can also be called with any class that doesn't have the bar method, and good luck deciphering the compiler error for it when it's nested 3 levels dee
by Maxatar 2y ago
Because it can also be called with any class that doesn't have the bar method, and good luck deciphering the compiler error for it when it's nested 3 levels deep into some far corner of the STL.
- lbhdc 2y agoThat is what concepts fix. It lets you enforce at build time that `t` does have member `.bar()`.
- deleted 2y ago[deleted]