Fix ODR violation: namespace-scope helpers should not be declared 'static'.
authorRichard Smith <richard-llvm@metafoo.co.uk>
Mon, 27 Aug 2018 21:41:50 +0000 (21:41 +0000)
committerRichard Smith <richard-llvm@metafoo.co.uk>
Mon, 27 Aug 2018 21:41:50 +0000 (21:41 +0000)
llvm-svn: 340778

libcxx/include/variant

index f9098f4..6c7dca2 100644 (file)
@@ -1320,7 +1320,7 @@ constexpr bool holds_alternative(const variant<_Types...>& __v) noexcept {
 
 template <size_t _Ip, class _Vp>
 inline _LIBCPP_INLINE_VISIBILITY
-static constexpr auto&& __generic_get(_Vp&& __v) {
+constexpr auto&& __generic_get(_Vp&& __v) {
   using __variant_detail::__access::__variant;
   if (!__holds_alternative<_Ip>(__v)) {
     __throw_bad_variant_access();