Amend 9b1dc338b2. Fix compilation in GCC 4.9

This commit is contained in:
Yuriy Skalko 2020-11-15 22:36:22 +02:00
parent e94c7871cc
commit 888ff9c114

View File

@ -73,7 +73,7 @@ inline Changer noChange()
/// To apply the change conditionally, one can write:
/// Changer dummy = (cond) ? changeVar(ref, val) : noChange();
template <typename X>
inline Changer changeVar(X & ref, X const val)
inline RefChanger<X> changeVar(X & ref, X const val)
{
auto rc = make_save(ref);
ref = val;