native_cv_error.cpp 550 B

1234567891011121314151617181920
  1. // Copyright (C) 2006-2009, 2012 Alexander Nasonov
  2. // Copyright (C) 2012 Lorenzo Caminiti
  3. // Distributed under the Boost Software License, Version 1.0
  4. // (see accompanying file LICENSE_1_0.txt or a copy at
  5. // http://www.boost.org/LICENSE_1_0.txt)
  6. // Home at http://www.boost.org/libs/scope_exit
  7. #include <boost/scope_exit.hpp>
  8. #include <boost/typeof/typeof.hpp>
  9. #include <boost/typeof/std/string.hpp>
  10. #include <string>
  11. int main(void) {
  12. std::string const volatile s;
  13. BOOST_SCOPE_EXIT( (&s) ) {
  14. s = "";
  15. } BOOST_SCOPE_EXIT_END
  16. }