Rewrite code to prevent Visual Studio 2014 compilation error.