From ed27365a418d608f6ff2268ad93da5177caa647b Mon Sep 17 00:00:00 2001 From: Allison Vacanti Date: Tue, 19 Oct 2021 12:26:02 -0400 Subject: [PATCH] Disable portion of test due to GCC 7 bug. Fixes #39. --- testing/enum_type_list.cu | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/testing/enum_type_list.cu b/testing/enum_type_list.cu index 293bf17..05b2605 100644 --- a/testing/enum_type_list.cu +++ b/testing/enum_type_list.cu @@ -159,11 +159,16 @@ void test_unscoped_enum_type_strings() using val_2 = nvbench::tl::get<1, values>; using val_3 = nvbench::tl::get<2, values>; ASSERT((nvbench::type_strings::input_string() == "1")); - ASSERT((nvbench::type_strings::description() == "unscoped_val_1")); ASSERT((nvbench::type_strings::input_string() == "2")); - ASSERT((nvbench::type_strings::description() == "unscoped_val_2")); ASSERT((nvbench::type_strings::input_string() == "3")); + + // There's a gcc bug (fixed in gcc8) that causes these templates to resolve + // incorrectly. See NVIDIA/nvbench#39 and NVBug 3404609 for details. +#if defined(__GNUC__) && __GNUC_ > 7 + ASSERT((nvbench::type_strings::description() == "unscoped_val_1")); + ASSERT((nvbench::type_strings::description() == "unscoped_val_2")); ASSERT((nvbench::type_strings::description() == "unscoped_val_3")); +#endif } int main()