## Reference

### Header <boost/scope/defer.hpp>

This header contains definition of `defer_guard` template.

    BOOST_SCOPE_DEFER

    namespace boost {
      namespace scope {
        template<typename Func> class defer_guard;
      }
    }

### Header <boost/scope/error_code_checker.hpp>

This header contains definition of `error_code_checker` type.

    namespace boost {
      namespace scope {
        template<typename ErrorCode> class error_code_checker;
        template<typename ErrorCode>
          error_code_checker< ErrorCode > check_error_code(ErrorCode &);
      }
    }

### Header <boost/scope/exception_checker.hpp>

This header contains definition of `exception_checker` type.

    namespace boost {
      namespace scope {
        class exception_checker;
        exception_checker check_exception();
      }
    }

### Header <boost/scope/fd_deleter.hpp>

This header contains definition of a deleter function object for POSIX-like file descriptors for use with `unique_resource`.

    namespace boost {
      namespace scope {
        struct fd_deleter;
      }
    }

### Header <boost/scope/fd_resource_traits.hpp>

This header contains definition of `unique_resource` traits for compatibility with POSIX-like file descriptors.

    namespace boost {
      namespace scope {
        struct fd_resource_traits;
      }
    }

### Header <boost/scope/scope_exit.hpp>

This header contains definition of `scope_exit` template.

    namespace boost {
      namespace scope {
        class always_true;
        template<typename Func, typename Cond = always_true> class scope_exit;
        template<typename F>
          scope_exit< typename std::decay< F >::type >
          make_scope_exit(F &&, bool = true);
        template<typename F, typename C>
          scope_exit< typename std::decay< F >::type, typename std::decay< C >::type >
          make_scope_exit(F &&, C &&, bool = true);
      }
    }

### Header <boost/scope/scope_fail.hpp>

This header contains definition of `scope_fail` template.

    namespace boost {
      namespace scope {
        template<typename Func, typename Cond = exception_checker> class scope_fail;
        template<typename F>
          scope_fail< typename std::decay< F >::type >
          make_scope_fail(F &&, bool = true);
        template<typename F, typename C>
          scope_fail< typename std::decay< F >::type, typename std::decay< C >::type >
          make_scope_fail(F &&, C &&, bool = true);
      }
    }

### Header <boost/scope/scope_success.hpp>

This header contains definition of `scope_success` template.

    namespace boost {
      namespace scope {
        template<typename Func, typename Cond = exception_checker>
          class scope_success;
        template<typename F>
          scope_success< typename std::decay< F >::type >
          make_scope_success(F &&, bool = true);
        template<typename F, typename C>
          scope_success< typename std::decay< F >::type, typename std::decay< C >::type >
          make_scope_success(F &&, C &&, bool = true);
      }
    }

### Header <boost/scope/unique_fd.hpp>

This header contains definition of `unique_fd` type.

    namespace boost {
      namespace scope {
        typedef unique_resource< int, fd_deleter, fd_resource_traits > unique_fd;  // Unique POSIX-like file descriptor resource.
      }
    }

### Header <boost/scope/unique_resource.hpp>

This header contains definition of `unique_resource` template.

    namespace boost {
      namespace scope {
        struct default_resource_t;
        template<auto DefaultValue, auto... UnallocatedValues>
          struct unallocated_resource;

        default_resource_t default_resource;    // Keyword representing default, unallocated resource argument.
        template<typename Resource, typename Deleter,
                 typename Invalid = typename std::decay< Resource >::type>
          unique_resource< typename std::decay< Resource >::type, typename std::decay< Deleter >::type >
          make_unique_resource_checked(Resource &&, Invalid const &, Deleter &&);
      }
    }

### Header <boost/scope/unique_resource_fwd.hpp>

This header contains forward declaration of `unique_resource` template.

    namespace boost {
      namespace scope {
        template<typename Resource, typename Deleter, typename Traits = void>
          class unique_resource;
      }
    }