Skip to content

Commit e82d869

Browse files
author
Julian LALU
committed
Fix EBCO for MSVC
1 parent 68cd4b4 commit e82d869

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

interface/core/containers/compressed_tuple.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,20 @@ namespace hud
7272
namespace details::compressed_tuple
7373
{
7474

75+
/** We need this to force MSVC to do EBCO of multiple inheritance. */
76+
#if defined(HD_COMPILER_CLANG_CL) || defined(HD_COMPILER_MSVC)
77+
#define EBCO_MSVC __declspec(empty_bases)
78+
#else
79+
#define EBCO_MSVC
80+
#endif
81+
7582
/**
7683
* compressed_tuple_leaf is one compressed_tuple content associated with an index
7784
* @tparam leaf_index The index of the leaf
7885
* @tparam type_t The type of the content
7986
*/
8087
template<usize leaf_index, typename type_t>
81-
struct compressed_tuple_leaf
88+
struct EBCO_MSVC compressed_tuple_leaf
8289
: type_t
8390
{
8491

@@ -207,13 +214,6 @@ namespace hud
207214
template<typename index_seq_t, typename... types_t>
208215
struct compressed_tuple_impl;
209216

210-
/** We need this to force MSVC to do EBCO of multiple inheritance. */
211-
#if defined(HD_COMPILER_CLANG_CL) || defined(HD_COMPILER_MSVC)
212-
#define EBCO_MSVC __declspec(empty_bases)
213-
#else
214-
#define EBCO_MSVC
215-
#endif
216-
217217
template<usize... indices, typename... types_t>
218218
struct EBCO_MSVC compressed_tuple_impl<index_sequence<indices...>, types_t...>
219219
: tuple_leaf_select<indices, types_t>::type...

0 commit comments

Comments
 (0)