Avoid variable shadowing by template