exception.hpp 801 B

1234567891011121314151617181920212223242526272829303132333435
  1. // Copyright (c) 2016 Klemens D. Morgenstern
  2. //
  3. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  4. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. #ifndef BOOST_PROCESS_EXCEPTION_HPP_
  6. #define BOOST_PROCESS_EXCEPTION_HPP_
  7. #include <system_error>
  8. #include <boost/process/v1/detail/config.hpp>
  9. namespace boost
  10. {
  11. namespace process
  12. {
  13. BOOST_PROCESS_V1_INLINE namespace v1
  14. {
  15. ///The exception usually thrown by boost.process.v1.
  16. /** It merely inherits [std::system_error](http://en.cppreference.com/w/cpp/error/system_error)
  17. * but can then be distinguished in the catch-block from other system errors.
  18. *
  19. */
  20. struct process_error : std::system_error
  21. {
  22. using std::system_error::system_error;
  23. };
  24. }
  25. }
  26. }
  27. #endif /* BOOST_PROCESS_EXCEPTION_HPP_ */