title: Good way to prevent C++03 code from performing suboptimally in C++11?
body: <p>I had some C++03 code that implemented <code>swap</code> for certain classes, to make <code>std::sort</code> (and other functions) fast.</p>
  
  <p>Unfortunately for me, <code>std::sort</code> now seems to use <code>std::move</code>, which means my code is now <strong>much slower</strong> than it was in C++03.</p>
  
  <p>I know I can use <code>#if __cplusplus &gt;= 201103L</code> to conditionally define a move-constructor/move-assignment operator, but I'm wondering if there's a better way that doesn't use preprocessor hacks?</p>
  
  <p>(I'd like to avoid the proprocessor hacks because they would be ugly, since not only do I have to test for compiler versions like <code>_MSC_VER &gt;= 1600</code>, but also because they wouldn't work well with tools like <a href="http://www.lazycplusplus.com/">LZZ</a> that don't recognize C++11 move syntax but force me to preprocess the code.)</p>