1 | /* |
---|---|
2 | * Distributed under the Boost Software License, Version 1.0. |
3 | * (See accompanying file LICENSE_1_0.txt or copy at |
4 | * https://www.boost.org/LICENSE_1_0.txt) |
5 | * |
6 | * Copyright (c) 2023 Andrey Semashev |
7 | */ |
8 | /*! |
9 | * \file scope/unique_fd.hpp |
10 | * |
11 | * This header contains definition of \c unique_fd type. |
12 | */ |
13 | |
14 | #ifndef BOOST_SCOPE_UNIQUE_FD_HPP_INCLUDED_ |
15 | #define BOOST_SCOPE_UNIQUE_FD_HPP_INCLUDED_ |
16 | |
17 | #include <boost/scope/detail/config.hpp> |
18 | #include <boost/scope/unique_resource.hpp> |
19 | #include <boost/scope/fd_deleter.hpp> |
20 | #include <boost/scope/fd_resource_traits.hpp> |
21 | #include <boost/scope/detail/header.hpp> |
22 | |
23 | #ifdef BOOST_HAS_PRAGMA_ONCE |
24 | #pragma once |
25 | #endif |
26 | |
27 | namespace boost { |
28 | namespace scope { |
29 | |
30 | //! Unique POSIX-like file descriptor resource |
31 | using unique_fd = unique_resource< int, fd_deleter, fd_resource_traits >; |
32 | |
33 | } // namespace scope |
34 | } // namespace boost |
35 | |
36 | #include <boost/scope/detail/footer.hpp> |
37 | |
38 | #endif // BOOST_SCOPE_UNIQUE_FD_HPP_INCLUDED_ |
39 |