From 3efcd4e54b8b374c90b362d763a726b9e025efae Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Sun, 29 Jan 2017 20:59:02 +0000 Subject: Vendor import of libc++ release_40 branch r293443: https://llvm.org/svn/llvm-project/libcxx/branches/release_40@293443 --- include/stack | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'include/stack') diff --git a/include/stack b/include/stack index 228864e4709b..c797ea5ec6e9 100644 --- a/include/stack +++ b/include/stack @@ -55,7 +55,7 @@ public: void push(const value_type& x); void push(value_type&& x); - template reference emplace(Args&&... args); + template reference emplace(Args&&... args); // reference in C++17 void pop(); void swap(stack& c) noexcept(is_nothrow_swappable_v) @@ -199,8 +199,13 @@ public: #ifndef _LIBCPP_HAS_NO_VARIADICS template _LIBCPP_INLINE_VISIBILITY +#if _LIBCPP_STD_VER > 14 reference emplace(_Args&&... __args) { return c.emplace_back(_VSTD::forward<_Args>(__args)...);} +#else + void emplace(_Args&&... __args) + { c.emplace_back(_VSTD::forward<_Args>(__args)...);} +#endif #endif // _LIBCPP_HAS_NO_VARIADICS #endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES _LIBCPP_INLINE_VISIBILITY -- cgit v1.3