Hacker News new | ask | show | jobs
by nly 4324 days ago
You want to use 'T const&' as your argument type, not 'T', otherwise foo() will take a copy of anything you pass.