• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2016 Andrey Semashev
3  *
4  * Distributed under the Boost Software License, Version 1.0.
5  * See http://www.boost.org/LICENSE_1_0.txt
6  */
7 
8 #ifndef BOOST_WINAPI_LIMITS_HPP_INCLUDED_
9 #define BOOST_WINAPI_LIMITS_HPP_INCLUDED_
10 
11 #include <boost/winapi/basic_types.hpp>
12 #include <boost/winapi/detail/header.hpp>
13 
14 #ifdef BOOST_HAS_PRAGMA_ONCE
15 #pragma once
16 #endif
17 
18 namespace boost {
19 namespace winapi {
20 
21 #if defined( BOOST_USE_WINDOWS_H )
22 
23 BOOST_CONSTEXPR_OR_CONST DWORD_ MAX_PATH_ = MAX_PATH;
24 
25 #else
26 
27 BOOST_CONSTEXPR_OR_CONST DWORD_ MAX_PATH_ = 260;
28 
29 #endif
30 
31 #if defined( BOOST_USE_WINDOWS_H ) && !defined( BOOST_WINAPI_IS_MINGW )
32 
33 BOOST_CONSTEXPR_OR_CONST DWORD_ UNICODE_STRING_MAX_BYTES_ = UNICODE_STRING_MAX_BYTES;
34 BOOST_CONSTEXPR_OR_CONST DWORD_ UNICODE_STRING_MAX_CHARS_ = UNICODE_STRING_MAX_CHARS;
35 
36 #else
37 
38 BOOST_CONSTEXPR_OR_CONST DWORD_ UNICODE_STRING_MAX_BYTES_ = 65534;
39 BOOST_CONSTEXPR_OR_CONST DWORD_ UNICODE_STRING_MAX_CHARS_ = 32767;
40 
41 #endif
42 
43 BOOST_CONSTEXPR_OR_CONST DWORD_ max_path = MAX_PATH_;
44 BOOST_CONSTEXPR_OR_CONST DWORD_ unicode_string_max_bytes = UNICODE_STRING_MAX_BYTES_;
45 BOOST_CONSTEXPR_OR_CONST DWORD_ unicode_string_max_chars = UNICODE_STRING_MAX_CHARS_;
46 
47 }
48 }
49 
50 #include <boost/winapi/detail/footer.hpp>
51 
52 #endif // BOOST_WINAPI_LIMITS_HPP_INCLUDED_
53