diff --git a/test/std/containers/sequences/array/array.cons/initializer_list.pass.cpp b/test/std/containers/sequences/array/array.cons/initializer_list.pass.cpp index 34db59de..5e429adb 100644 --- a/test/std/containers/sequences/array/array.cons/initializer_list.pass.cpp +++ b/test/std/containers/sequences/array/array.cons/initializer_list.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.data/data.pass.cpp b/test/std/containers/sequences/array/array.data/data.pass.cpp index 80b7d063..d7aed70c 100644 --- a/test/std/containers/sequences/array/array.data/data.pass.cpp +++ b/test/std/containers/sequences/array/array.data/data.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.data/data_const.pass.cpp b/test/std/containers/sequences/array/array.data/data_const.pass.cpp index 1c9abdd0..58840e94 100644 --- a/test/std/containers/sequences/array/array.data/data_const.pass.cpp +++ b/test/std/containers/sequences/array/array.data/data_const.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.fill/fill.pass.cpp b/test/std/containers/sequences/array/array.fill/fill.pass.cpp index f98dbbda..5bc42ceb 100644 --- a/test/std/containers/sequences/array/array.fill/fill.pass.cpp +++ b/test/std/containers/sequences/array/array.fill/fill.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.size/size.pass.cpp b/test/std/containers/sequences/array/array.size/size.pass.cpp index 89b893af..a833fdc0 100644 --- a/test/std/containers/sequences/array/array.size/size.pass.cpp +++ b/test/std/containers/sequences/array/array.size/size.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.special/swap.pass.cpp b/test/std/containers/sequences/array/array.special/swap.pass.cpp index 82ce904d..c1b0b235 100644 --- a/test/std/containers/sequences/array/array.special/swap.pass.cpp +++ b/test/std/containers/sequences/array/array.special/swap.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.swap/swap.pass.cpp b/test/std/containers/sequences/array/array.swap/swap.pass.cpp index 22bf6579..651798e1 100644 --- a/test/std/containers/sequences/array/array.swap/swap.pass.cpp +++ b/test/std/containers/sequences/array/array.swap/swap.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.tuple/get.fail.cpp b/test/std/containers/sequences/array/array.tuple/get.fail.cpp index 6b2385da..13323dd8 100644 --- a/test/std/containers/sequences/array/array.tuple/get.fail.cpp +++ b/test/std/containers/sequences/array/array.tuple/get.fail.cpp @@ -20,7 +20,10 @@ #include #include "test_macros.h" -#include "../suppress_array_warnings.h" + +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.tuple/get.pass.cpp b/test/std/containers/sequences/array/array.tuple/get.pass.cpp index c4557078..4f210c4f 100644 --- a/test/std/containers/sequences/array/array.tuple/get.pass.cpp +++ b/test/std/containers/sequences/array/array.tuple/get.pass.cpp @@ -16,7 +16,9 @@ #include "test_macros.h" -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" #if TEST_STD_VER > 11 diff --git a/test/std/containers/sequences/array/array.tuple/get_const.pass.cpp b/test/std/containers/sequences/array/array.tuple/get_const.pass.cpp index ddc2ab28..04606bf6 100644 --- a/test/std/containers/sequences/array/array.tuple/get_const.pass.cpp +++ b/test/std/containers/sequences/array/array.tuple/get_const.pass.cpp @@ -16,7 +16,9 @@ #include "test_macros.h" -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/array.tuple/get_rv.pass.cpp b/test/std/containers/sequences/array/array.tuple/get_rv.pass.cpp index 412c7c78..72ef49b1 100644 --- a/test/std/containers/sequences/array/array.tuple/get_rv.pass.cpp +++ b/test/std/containers/sequences/array/array.tuple/get_rv.pass.cpp @@ -18,7 +18,9 @@ #include #include -#include "../suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/at.pass.cpp b/test/std/containers/sequences/array/at.pass.cpp index c4f7acb9..c271788f 100644 --- a/test/std/containers/sequences/array/at.pass.cpp +++ b/test/std/containers/sequences/array/at.pass.cpp @@ -19,7 +19,9 @@ #include "test_macros.h" -#include "suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/begin.pass.cpp b/test/std/containers/sequences/array/begin.pass.cpp index a6218ae0..b12ffc85 100644 --- a/test/std/containers/sequences/array/begin.pass.cpp +++ b/test/std/containers/sequences/array/begin.pass.cpp @@ -14,7 +14,9 @@ #include #include -#include "suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/front_back.pass.cpp b/test/std/containers/sequences/array/front_back.pass.cpp index ebe3a180..bccaade9 100644 --- a/test/std/containers/sequences/array/front_back.pass.cpp +++ b/test/std/containers/sequences/array/front_back.pass.cpp @@ -19,7 +19,9 @@ #include "test_macros.h" -#include "suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/containers/sequences/array/indexing.pass.cpp b/test/std/containers/sequences/array/indexing.pass.cpp index c550d141..5ccb0b48 100644 --- a/test/std/containers/sequences/array/indexing.pass.cpp +++ b/test/std/containers/sequences/array/indexing.pass.cpp @@ -19,7 +19,9 @@ #include "test_macros.h" -#include "suppress_array_warnings.h" +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" int main() { diff --git a/test/std/experimental/utilities/tuple/tuple.apply/arg_type.pass.cpp b/test/std/experimental/utilities/tuple/tuple.apply/arg_type.pass.cpp index 56dc3c6a..cb44707f 100644 --- a/test/std/experimental/utilities/tuple/tuple.apply/arg_type.pass.cpp +++ b/test/std/experimental/utilities/tuple/tuple.apply/arg_type.pass.cpp @@ -20,6 +20,11 @@ #include #include +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" + + namespace ex = std::experimental; int call_with_value(int x, int y) { return (x + y); } diff --git a/test/std/experimental/utilities/tuple/tuple.apply/extended_types.pass.cpp b/test/std/experimental/utilities/tuple/tuple.apply/extended_types.pass.cpp index 32255492..0c5170f2 100644 --- a/test/std/experimental/utilities/tuple/tuple.apply/extended_types.pass.cpp +++ b/test/std/experimental/utilities/tuple/tuple.apply/extended_types.pass.cpp @@ -22,6 +22,10 @@ #include #include +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" + int count = 0; struct A_int_0 diff --git a/test/std/experimental/utilities/tuple/tuple.apply/types.pass.cpp b/test/std/experimental/utilities/tuple/tuple.apply/types.pass.cpp index 5d3d564c..52eec276 100644 --- a/test/std/experimental/utilities/tuple/tuple.apply/types.pass.cpp +++ b/test/std/experimental/utilities/tuple/tuple.apply/types.pass.cpp @@ -20,6 +20,10 @@ #include #include +// std::array is explicitly allowed to be initialized with A a = { init-list };. +// Disable the missing braces warning for this reason. +#include "disable_missing_braces_warning.h" + namespace ex = std::experimental; int count = 0; diff --git a/test/std/containers/sequences/array/suppress_array_warnings.h b/test/support/disable_missing_braces_warning.h similarity index 55% rename from test/std/containers/sequences/array/suppress_array_warnings.h rename to test/support/disable_missing_braces_warning.h index 1dde3d31..967a87ab 100644 --- a/test/std/containers/sequences/array/suppress_array_warnings.h +++ b/test/support/disable_missing_braces_warning.h @@ -1,8 +1,8 @@ -#ifndef SUPPRESS_ARRAY_WARNINGS_H -#define SUPPRESS_ARRAY_WARNINGS_H +#ifndef SUPPORT_DISABLE_MISSING_BRACES_WARNING_H +#define SUPPORT_DISABLE_MISSING_BRACES_WARNING_H // std::array is explicitly allowed to be initialized with A a = { init-list };. // Disable the missing braces warning for this reason. #pragma GCC diagnostic ignored "-Wmissing-braces" -#endif // SUPPRESS_ARRAY_WARNINGS +#endif // SUPPORT_DISABLE_MISSING_BRACES_WARNING_H