diff options
Diffstat (limited to 'var/spack/repos/builtin/packages/mpark-variant')
-rw-r--r-- | var/spack/repos/builtin/packages/mpark-variant/nvcc.patch | 40 | ||||
-rw-r--r-- | var/spack/repos/builtin/packages/mpark-variant/package.py | 5 |
2 files changed, 44 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/mpark-variant/nvcc.patch b/var/spack/repos/builtin/packages/mpark-variant/nvcc.patch new file mode 100644 index 0000000000..9bd7e60d5b --- /dev/null +++ b/var/spack/repos/builtin/packages/mpark-variant/nvcc.patch @@ -0,0 +1,40 @@ +From d7fb6201cbe830c2aef35b3fd0df040f9eae6d4d Mon Sep 17 00:00:00 2001 +From: Gavin Ridley <gavin.keith.ridley@gmail.com> +Date: Tue, 31 Dec 2019 14:42:14 -0500 +Subject: [PATCH] now compiles in nvcc 10.2 + +--- + include/mpark/variant.hpp | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/include/mpark/variant.hpp b/include/mpark/variant.hpp +index ef496619b..f4848db88 100644 +--- a/include/mpark/variant.hpp ++++ b/include/mpark/variant.hpp +@@ -2001,20 +2001,20 @@ namespace mpark { + #ifdef MPARK_CPP14_CONSTEXPR + namespace detail { + +- inline constexpr bool all(std::initializer_list<bool> bs) { ++ inline constexpr bool any(std::initializer_list<bool> bs) { + for (bool b : bs) { +- if (!b) { +- return false; ++ if (b) { ++ return true; + } + } +- return true; ++ return false; + } + + } // namespace detail + + template <typename Visitor, typename... Vs> + inline constexpr decltype(auto) visit(Visitor &&visitor, Vs &&... vs) { +- return (detail::all({!vs.valueless_by_exception()...}) ++ return (!detail::any({vs.valueless_by_exception()...}) + ? (void)0 + : throw_bad_variant_access()), + detail::visitation::variant::visit_value( + diff --git a/var/spack/repos/builtin/packages/mpark-variant/package.py b/var/spack/repos/builtin/packages/mpark-variant/package.py index afeb4bd7e5..85b9bfb82d 100644 --- a/var/spack/repos/builtin/packages/mpark-variant/package.py +++ b/var/spack/repos/builtin/packages/mpark-variant/package.py @@ -1,4 +1,4 @@ -# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other +# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) @@ -16,5 +16,8 @@ class MparkVariant(CMakePackage): version('1.4.0', sha256='8f6b28ab3640b5d76d5b6664dda7257a4405ce59179220431b8fd196c79b2ecb') version('1.3.0', sha256='d0f7e41f818fcc839797a8017e76b8b66b323651c304cff641a83a56ae9943c6') + # Ref.: https://github.com/mpark/variant/pull/73 + patch('nvcc.patch', when='@:1.4.0') + conflicts('%gcc@:4.7') conflicts('%clang@:3.5') |