Skip to content

Commit 61a7a1b

Browse files
committed
restructure the if-else for has_include
1 parent b0de67c commit 61a7a1b

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

include/beman/any_view/detail/unique_address.hpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
#ifndef BEMAN_ANY_VIEW_DETAIL_UNIQUE_ADDRESS_HPP
44
#define BEMAN_ANY_VIEW_DETAIL_UNIQUE_ADDRESS_HPP
55

6-
//clang-format off
7-
#if !defined(__has_include) || __has_include(<beman/any_view/config.hpp>)
8-
#include <beman/any_view/config.hpp>
6+
#if !defined(__has_include)
7+
# if __has_include(<beman/any_view/config.hpp>)
8+
# include <beman/any_view/config.hpp>
9+
# endif
910
#else
10-
// if the config.hpp file does not exist because this is in godbolt
11-
// or another context where cmake is not run, default to the correct
12-
// answer.
13-
#if (_MSC_VER)
14-
#define BEMAN_ANY_VIEW_NO_UNIQUE_ADDRESS() [[msvc::no_unique_address]]
15-
#else
16-
#define BEMAN_ANY_VIEW_NO_UNIQUE_ADDRESS() [[no_unique_address]]
17-
#endif
11+
// if the config.hpp file does not exist because this is in godbolt
12+
// or another context where cmake is not run, default to the correct
13+
// answer.
14+
# if (_MSC_VER)
15+
# define BEMAN_ANY_VIEW_NO_UNIQUE_ADDRESS() [[msvc::no_unique_address]]
16+
# else
17+
# define BEMAN_ANY_VIEW_NO_UNIQUE_ADDRESS() [[no_unique_address]]
18+
# endif
1819
#endif
19-
//clang-format on
2020

2121
#endif

0 commit comments

Comments
 (0)