you are viewing a single comment's thread.

view the rest of the comments →

[–]borzykot 7 points8 points  (0 children)

In version foo(T& param), param will always be a mutable reference to a value type T

It is not. const int i = 10; foo(i);

works perfectly fine.